diff options
author | daniel oeh <daniel.oeh@gmail.com> | 2013-04-20 17:14:43 +0200 |
---|---|---|
committer | daniel oeh <daniel.oeh@gmail.com> | 2013-04-20 17:14:43 +0200 |
commit | d086579e096cbbc3a437cb7e1d775248ad9de5c1 (patch) | |
tree | d7e7b48e47d25d5c969bc2dcc640764125330264 /src/de/danoeh/antennapod/activity | |
parent | 6eb0c58a085baba2cdb48512e9ab7bd433416a15 (diff) | |
download | AntennaPod-d086579e096cbbc3a437cb7e1d775248ad9de5c1.zip |
Episode cache size can now be set to 'unlimited'
Diffstat (limited to 'src/de/danoeh/antennapod/activity')
-rw-r--r-- | src/de/danoeh/antennapod/activity/PreferenceActivity.java | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/de/danoeh/antennapod/activity/PreferenceActivity.java b/src/de/danoeh/antennapod/activity/PreferenceActivity.java index 994cd2df6..c59b14c03 100644 --- a/src/de/danoeh/antennapod/activity/PreferenceActivity.java +++ b/src/de/danoeh/antennapod/activity/PreferenceActivity.java @@ -205,9 +205,15 @@ public class PreferenceActivity extends SherlockPreferenceActivity { } private void setEpisodeCacheSizeText(int cacheSize) { - findPreference(UserPreferences.PREF_EPISODE_CACHE_SIZE).setSummary( - Integer.toString(cacheSize) - + getString(R.string.episodes_suffix)); + String s; + if (cacheSize == getResources().getInteger( + R.integer.episode_cache_size_unlimited)) { + s = getString(R.string.pref_episode_cache_unlimited); + } else { + s = Integer.toString(cacheSize) + + getString(R.string.episodes_suffix); + } + findPreference(UserPreferences.PREF_EPISODE_CACHE_SIZE).setSummary(s); } private void setDataFolderText() { |