Merge pull request #1789 from mfietz/issue/358-gpodder-information

Show gpodder information
This commit is contained in:
Tom Hennen 2016-03-22 17:32:30 -04:00
commit 05ef0a91a5
2 changed files with 9 additions and 0 deletions

View File

@ -453,6 +453,14 @@ public class PreferenceController implements SharedPreferences.OnSharedPreferenc
ui.findPreference(PreferenceController.PREF_GPODNET_SETLOGIN_INFORMATION).setEnabled(loggedIn);
ui.findPreference(PreferenceController.PREF_GPODNET_SYNC).setEnabled(loggedIn);
ui.findPreference(PreferenceController.PREF_GPODNET_LOGOUT).setEnabled(loggedIn);
if(loggedIn) {
String format = ui.getActivity().getString(R.string.pref_gpodnet_login_status);
String summary = String.format(format, GpodnetPreferences.getUsername(),
GpodnetPreferences.getDeviceID());
ui.findPreference(PreferenceController.PREF_GPODNET_LOGOUT).setSummary(Html.fromHtml(summary));
} else {
ui.findPreference(PreferenceController.PREF_GPODNET_LOGOUT).setSummary(null);
}
ui.findPreference(PreferenceController.PREF_GPODNET_HOSTNAME).setSummary(GpodnetPreferences.getHostname());
}

View File

@ -365,6 +365,7 @@
<string name="pref_gpodnet_sync_title">Sync now</string>
<string name="pref_gpodnet_sync_sum">Sync subscriptions and episode states with gpodder.net</string>
<string name="pref_gpodnet_sync_started">Sync started</string>
<string name="pref_gpodnet_login_status"><![CDATA[Logged in as <i>%1$s</i> with device <i>%2$s</i>]]></string>
<string name="pref_playback_speed_title">Playback Speeds</string>
<string name="pref_playback_speed_sum">Customize the speeds available for variable speed audio playback</string>
<string name="pref_fast_forward">Fast forward time</string>