Prepare to publish
This commit is contained in:
parent
a2b70ced16
commit
2c39156d7e
3 changed files with 14 additions and 58 deletions
|
|
@ -115,7 +115,9 @@ public class AlbumCoverPagerAdapter extends CustomFragmentStatePagerAdapter {
|
||||||
@Override
|
@Override
|
||||||
public void onViewCreated(View view, Bundle savedInstanceState) {
|
public void onViewCreated(View view, Bundle savedInstanceState) {
|
||||||
super.onViewCreated(view, savedInstanceState);
|
super.onViewCreated(view, savedInstanceState);
|
||||||
forceSquareAlbumCover(PreferenceUtil.getInstance(getContext()).forceSquareAlbumCover());
|
forceSquareAlbumCover(false);
|
||||||
|
// TODO
|
||||||
|
// forceSquareAlbumCover(PreferenceUtil.getInstance(getContext()).forceSquareAlbumCover());
|
||||||
PreferenceUtil.getInstance(getActivity()).registerOnSharedPreferenceChangedListener(this);
|
PreferenceUtil.getInstance(getActivity()).registerOnSharedPreferenceChangedListener(this);
|
||||||
loadAlbumCover();
|
loadAlbumCover();
|
||||||
}
|
}
|
||||||
|
|
@ -147,7 +149,7 @@ public class AlbumCoverPagerAdapter extends CustomFragmentStatePagerAdapter {
|
||||||
new SimpleImageLoadingListener() {
|
new SimpleImageLoadingListener() {
|
||||||
@Override
|
@Override
|
||||||
public void onLoadingFailed(String imageUri, View view, @Nullable FailReason failReason) {
|
public void onLoadingFailed(String imageUri, View view, @Nullable FailReason failReason) {
|
||||||
if(getActivity() != null) {
|
if (getActivity() != null) {
|
||||||
setColor(ColorUtil.resolveColor(getActivity(), R.attr.default_bar_color));
|
setColor(ColorUtil.resolveColor(getActivity(), R.attr.default_bar_color));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -168,7 +170,8 @@ public class AlbumCoverPagerAdapter extends CustomFragmentStatePagerAdapter {
|
||||||
public void onSharedPreferenceChanged(SharedPreferences sharedPreferences, String key) {
|
public void onSharedPreferenceChanged(SharedPreferences sharedPreferences, String key) {
|
||||||
switch (key) {
|
switch (key) {
|
||||||
case PreferenceUtil.FORCE_SQUARE_ALBUM_COVER:
|
case PreferenceUtil.FORCE_SQUARE_ALBUM_COVER:
|
||||||
forceSquareAlbumCover(PreferenceUtil.getInstance(getActivity()).forceSquareAlbumCover());
|
// TODO
|
||||||
|
// forceSquareAlbumCover(PreferenceUtil.getInstance(getActivity()).forceSquareAlbumCover());
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -206,4 +206,5 @@
|
||||||
<string name="website">Website</string>
|
<string name="website">Website</string>
|
||||||
<string name="loading_products">Loading products…</string>
|
<string name="loading_products">Loading products…</string>
|
||||||
<string name="up_next">Up next</string>
|
<string name="up_next">Up next</string>
|
||||||
|
<string name="pref_title_now_playing_layout">Now playing layout</string>
|
||||||
</resources>
|
</resources>
|
||||||
|
|
|
||||||
|
|
@ -3,62 +3,14 @@
|
||||||
|
|
||||||
<com.kabouzeid.gramophone.prefs.DynamicPreferenceCategory android:title="@string/pref_header_now_playing_screen">
|
<com.kabouzeid.gramophone.prefs.DynamicPreferenceCategory android:title="@string/pref_header_now_playing_screen">
|
||||||
|
|
||||||
<CheckBoxPreference
|
<com.afollestad.materialdialogs.prefs.MaterialListPreference
|
||||||
android:defaultValue="false"
|
android:enabled="false"
|
||||||
android:key="opaque_statusbar_now_playing"
|
android:key="now_playing_layout"
|
||||||
android:layout="@layout/preference_custom"
|
android:layout="@layout/preference_custom"
|
||||||
android:summary="@string/pref_summary_opaque_statusbar_now_playing"
|
android:negativeButtonText="@null"
|
||||||
android:title="@string/pref_title_opaque_statusbar_now_playing"
|
android:positiveButtonText="@null"
|
||||||
android:widgetLayout="@layout/preference_dynamic_checkbox" />
|
android:summary="Coming soon"
|
||||||
|
android:title="@string/pref_title_now_playing_layout" />
|
||||||
<CheckBoxPreference
|
|
||||||
android:defaultValue="false"
|
|
||||||
android:dependency="opaque_statusbar_now_playing"
|
|
||||||
android:key="opaque_toolbar_now_playing"
|
|
||||||
android:layout="@layout/preference_custom"
|
|
||||||
android:summary="@string/pref_summary_opaque_toolbar_now_playing"
|
|
||||||
android:title="@string/pref_title_opaque_toolbar_now_playing"
|
|
||||||
android:widgetLayout="@layout/preference_dynamic_checkbox" />
|
|
||||||
|
|
||||||
<CheckBoxPreference
|
|
||||||
android:defaultValue="false"
|
|
||||||
android:key="force_square_album_art"
|
|
||||||
android:layout="@layout/preference_custom"
|
|
||||||
android:summary="@string/pref_summary_force_square_album_art"
|
|
||||||
android:title="@string/pref_title_force_square_album_art"
|
|
||||||
android:widgetLayout="@layout/preference_dynamic_checkbox" />
|
|
||||||
|
|
||||||
<CheckBoxPreference
|
|
||||||
android:defaultValue="false"
|
|
||||||
android:key="larger_title_box_now_playing"
|
|
||||||
android:layout="@layout/preference_custom"
|
|
||||||
android:summary="@string/pref_summary_larger_title_box_now_playing"
|
|
||||||
android:title="@string/pref_title_larger_title_box_now_playing"
|
|
||||||
android:widgetLayout="@layout/preference_dynamic_checkbox" />
|
|
||||||
|
|
||||||
<CheckBoxPreference
|
|
||||||
android:defaultValue="false"
|
|
||||||
android:key="alternative_progress_slider_now_playing"
|
|
||||||
android:layout="@layout/preference_custom"
|
|
||||||
android:summary="@string/pref_summary_alternative_progress_slider_now_playing"
|
|
||||||
android:title="@string/pref_title_alternative_progress_slider_now_playing"
|
|
||||||
android:widgetLayout="@layout/preference_dynamic_checkbox" />
|
|
||||||
|
|
||||||
<CheckBoxPreference
|
|
||||||
android:defaultValue="false"
|
|
||||||
android:key="playback_controller_card_now_playing"
|
|
||||||
android:layout="@layout/preference_custom"
|
|
||||||
android:summary="@string/pref_summary_playback_controller_card_now_playing"
|
|
||||||
android:title="@string/pref_title_playback_controller_card_now_playing"
|
|
||||||
android:widgetLayout="@layout/preference_dynamic_checkbox" />
|
|
||||||
|
|
||||||
<CheckBoxPreference
|
|
||||||
android:defaultValue="true"
|
|
||||||
android:key="color_playback_controls_now_playing"
|
|
||||||
android:layout="@layout/preference_custom"
|
|
||||||
android:summary="@string/pref_summary_colored_playback_controls_now_playing"
|
|
||||||
android:title="@string/pref_title_colored_playback_controls_now_playing"
|
|
||||||
android:widgetLayout="@layout/preference_dynamic_checkbox" />
|
|
||||||
|
|
||||||
</com.kabouzeid.gramophone.prefs.DynamicPreferenceCategory>
|
</com.kabouzeid.gramophone.prefs.DynamicPreferenceCategory>
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue