Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The MobileLibraryBrowser is now fed from the database.
However, only the Artist tab works for now. Updated Android project with new changes. Related to issue #406 and issue #409.
- Loading branch information
1 parent
88d3d3f
commit 19d5d7b
Showing
30 changed files
with
1,109 additions
and
983 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
104 changes: 53 additions & 51 deletions
104
MPfm/MPfm.Android/Classes/Fragments/AudioPreferencesFragment.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,51 +1,53 @@ | ||
// Copyright © 2011-2013 Yanick Castonguay | ||
// | ||
// This file is part of MPfm. | ||
// | ||
// MPfm is free software: you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License as published by | ||
// the Free Software Foundation, either version 3 of the License, or | ||
// (at your option) any later version. | ||
// | ||
// MPfm is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU General Public License | ||
// along with MPfm. If not, see <http://www.gnu.org/licenses/>. | ||
|
||
using System; | ||
using Android.App; | ||
using Android.OS; | ||
using Android.Views; | ||
using Android.Widget; | ||
using MPfm.Android.Classes.Fragments.Base; | ||
using MPfm.MVP.Views; | ||
|
||
namespace MPfm.Android.Classes.Fragments | ||
{ | ||
public class AudioPreferencesFragment : BaseFragment, IAudioPreferencesView, View.IOnClickListener | ||
{ | ||
private View _view; | ||
private TextView _lblTitle; | ||
|
||
public AudioPreferencesFragment(Action<IBaseView> onViewReady) | ||
: base(onViewReady) | ||
{ | ||
|
||
} | ||
|
||
public override View OnCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) | ||
{ | ||
_view = inflater.Inflate(Resource.Layout.Fragment_AudioPreferences, container, false); | ||
_lblTitle = _view.FindViewById<TextView>(Resource.Id.fragment_audioSettings_lblTitle); | ||
return _view; | ||
} | ||
|
||
public void OnClick(View v) | ||
{ | ||
|
||
} | ||
} | ||
} | ||
// Copyright © 2011-2013 Yanick Castonguay | ||
// | ||
// This file is part of MPfm. | ||
// | ||
// MPfm is free software: you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License as published by | ||
// the Free Software Foundation, either version 3 of the License, or | ||
// (at your option) any later version. | ||
// | ||
// MPfm is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU General Public License | ||
// along with MPfm. If not, see <http://www.gnu.org/licenses/>. | ||
|
||
using System; | ||
using Android.App; | ||
using Android.OS; | ||
using Android.Views; | ||
using Android.Widget; | ||
using MPfm.Android.Classes.Fragments.Base; | ||
using MPfm.MVP.Views; | ||
|
||
namespace MPfm.Android.Classes.Fragments | ||
{ | ||
public class AudioPreferencesFragment : BaseFragment, IAudioPreferencesView, View.IOnClickListener | ||
{ | ||
private View _view; | ||
private TextView _lblTitle; | ||
|
||
// Leave an empty constructor or the application will crash at runtime | ||
public AudioPreferencesFragment() : base(null) { } | ||
|
||
public AudioPreferencesFragment(Action<IBaseView> onViewReady) | ||
: base(onViewReady) | ||
{ | ||
} | ||
|
||
public override View OnCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) | ||
{ | ||
_view = inflater.Inflate(Resource.Layout.AudioPreferences, container, false); | ||
_lblTitle = _view.FindViewById<TextView>(Resource.Id.fragment_audioSettings_lblTitle); | ||
return _view; | ||
} | ||
|
||
public void OnClick(View v) | ||
{ | ||
|
||
} | ||
} | ||
} |
102 changes: 51 additions & 51 deletions
102
MPfm/MPfm.Android/Classes/Fragments/Base/BaseDialogFragment.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,51 +1,51 @@ | ||
// Copyright © 2011-2013 Yanick Castonguay | ||
// | ||
// This file is part of MPfm. | ||
// | ||
// MPfm is free software: you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License as published by | ||
// the Free Software Foundation, either version 3 of the License, or | ||
// (at your option) any later version. | ||
// | ||
// MPfm is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU General Public License | ||
// along with MPfm. If not, see <http://www.gnu.org/licenses/>. | ||
|
||
using System; | ||
using Android.App; | ||
using Android.OS; | ||
using MPfm.MVP.Views; | ||
|
||
namespace MPfm.Android.Classes.Fragments.Base | ||
{ | ||
public class BaseDialogFragment : DialogFragment, IBaseView | ||
{ | ||
protected Action<IBaseView> OnViewReady { get; set; } | ||
public Action<IBaseView> OnViewDestroy { get; set; } | ||
public void ShowView(bool shown) | ||
{ | ||
// Ignore on Android | ||
} | ||
|
||
public BaseDialogFragment(Action<IBaseView> onViewReady) | ||
{ | ||
this.OnViewReady = onViewReady; | ||
} | ||
|
||
public override void OnCreate(Bundle savedInstanceState) | ||
{ | ||
base.OnCreate(savedInstanceState); | ||
OnViewReady(this); | ||
} | ||
|
||
public override void OnDestroy() | ||
{ | ||
base.OnDestroy(); | ||
OnViewDestroy(this); | ||
} | ||
} | ||
} | ||
// Copyright © 2011-2013 Yanick Castonguay | ||
// | ||
// This file is part of MPfm. | ||
// | ||
// MPfm is free software: you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License as published by | ||
// the Free Software Foundation, either version 3 of the License, or | ||
// (at your option) any later version. | ||
// | ||
// MPfm is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU General Public License | ||
// along with MPfm. If not, see <http://www.gnu.org/licenses/>. | ||
|
||
using System; | ||
using Android.App; | ||
using Android.OS; | ||
using MPfm.MVP.Views; | ||
|
||
namespace MPfm.Android.Classes.Fragments.Base | ||
{ | ||
public class BaseDialogFragment : DialogFragment, IBaseView | ||
{ | ||
protected Action<IBaseView> OnViewReady { get; set; } | ||
public Action<IBaseView> OnViewDestroy { get; set; } | ||
public void ShowView(bool shown) | ||
{ | ||
// Ignore on Android | ||
} | ||
|
||
public BaseDialogFragment(Action<IBaseView> onViewReady) | ||
{ | ||
this.OnViewReady = onViewReady; | ||
} | ||
|
||
public override void OnCreate(Bundle savedInstanceState) | ||
{ | ||
base.OnCreate(savedInstanceState); | ||
if (OnViewReady != null) OnViewReady(this); | ||
} | ||
|
||
public override void OnDestroy() | ||
{ | ||
base.OnDestroy(); | ||
if (OnViewReady != null) OnViewDestroy(this); | ||
} | ||
} | ||
} |
102 changes: 51 additions & 51 deletions
102
MPfm/MPfm.Android/Classes/Fragments/Base/BaseFragment.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,51 +1,51 @@ | ||
// Copyright © 2011-2013 Yanick Castonguay | ||
// | ||
// This file is part of MPfm. | ||
// | ||
// MPfm is free software: you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License as published by | ||
// the Free Software Foundation, either version 3 of the License, or | ||
// (at your option) any later version. | ||
// | ||
// MPfm is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU General Public License | ||
// along with MPfm. If not, see <http://www.gnu.org/licenses/>. | ||
|
||
using System; | ||
using Android.App; | ||
using Android.OS; | ||
using MPfm.MVP.Views; | ||
|
||
namespace MPfm.Android.Classes.Fragments.Base | ||
{ | ||
public class BaseFragment : Fragment, IBaseView | ||
{ | ||
protected Action<IBaseView> OnViewReady { get; set; } | ||
public Action<IBaseView> OnViewDestroy { get; set; } | ||
public void ShowView(bool shown) | ||
{ | ||
// Ignore on Android | ||
} | ||
|
||
public BaseFragment(Action<IBaseView> onViewReady) | ||
{ | ||
this.OnViewReady = onViewReady; | ||
} | ||
|
||
public override void OnCreate(Bundle savedInstanceState) | ||
{ | ||
base.OnCreate(savedInstanceState); | ||
OnViewReady(this); | ||
} | ||
|
||
public override void OnDestroy() | ||
{ | ||
base.OnDestroy(); | ||
OnViewDestroy(this); | ||
} | ||
} | ||
} | ||
// Copyright © 2011-2013 Yanick Castonguay | ||
// | ||
// This file is part of MPfm. | ||
// | ||
// MPfm is free software: you can redistribute it and/or modify | ||
// it under the terms of the GNU General Public License as published by | ||
// the Free Software Foundation, either version 3 of the License, or | ||
// (at your option) any later version. | ||
// | ||
// MPfm is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
// GNU General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU General Public License | ||
// along with MPfm. If not, see <http://www.gnu.org/licenses/>. | ||
|
||
using System; | ||
using Android.App; | ||
using Android.OS; | ||
using MPfm.MVP.Views; | ||
|
||
namespace MPfm.Android.Classes.Fragments.Base | ||
{ | ||
public class BaseFragment : Fragment, IBaseView | ||
{ | ||
protected Action<IBaseView> OnViewReady { get; set; } | ||
public Action<IBaseView> OnViewDestroy { get; set; } | ||
public void ShowView(bool shown) | ||
{ | ||
// Ignore on Android | ||
} | ||
|
||
public BaseFragment(Action<IBaseView> onViewReady) | ||
{ | ||
this.OnViewReady = onViewReady; | ||
} | ||
|
||
public override void OnCreate(Bundle savedInstanceState) | ||
{ | ||
base.OnCreate(savedInstanceState); | ||
if (OnViewReady != null) OnViewReady(this); | ||
} | ||
|
||
public override void OnDestroy() | ||
{ | ||
base.OnDestroy(); | ||
if (OnViewReady != null) OnViewDestroy(this); | ||
} | ||
} | ||
} |
Oops, something went wrong.