[Android] Extract resource from hardcoded string
Geoffrey Métais
git at videolan.org
Mon May 18 14:39:43 CEST 2015
vlc-ports/android | branch: master | Geoffrey Métais <geoffrey.metais at gmail.com> | Mon May 18 14:26:02 2015 +0200| [9112115be8784a8c92f127bfbfc066e75c90cc37] | committer: Geoffrey Métais
Extract resource from hardcoded string
> http://git.videolan.org/gitweb.cgi/vlc-ports/android.git/?a=commit;h=9112115be8784a8c92f127bfbfc066e75c90cc37
---
vlc-android/res/values/strings.xml | 1 +
vlc-android/src/org/videolan/vlc/gui/dialogs/AdvOptionsDialog.java | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/vlc-android/res/values/strings.xml b/vlc-android/res/values/strings.xml
index 6645373..91e9592 100644
--- a/vlc-android/res/values/strings.xml
+++ b/vlc-android/res/values/strings.xml
@@ -326,6 +326,7 @@
<string name="audio_delay">Audio delay</string>
<string name="spu_delay">Subtitle delay</string>
+ <string name="sleep_time_not_set">none set</string>
<string name="network_shares_discovery">Looking for network shares...</string>
<string name="network_empty">This directory is empty.</string>
<string name="network_connection_needed">No connection to local network.</string>
diff --git a/vlc-android/src/org/videolan/vlc/gui/dialogs/AdvOptionsDialog.java b/vlc-android/src/org/videolan/vlc/gui/dialogs/AdvOptionsDialog.java
index cf1e4ad..97a415a 100644
--- a/vlc-android/src/org/videolan/vlc/gui/dialogs/AdvOptionsDialog.java
+++ b/vlc-android/src/org/videolan/vlc/gui/dialogs/AdvOptionsDialog.java
@@ -349,7 +349,7 @@ public class AdvOptionsDialog extends DialogFragment implements View.OnClickList
if (VLCApplication.sPlayerSleepTime != null)
text = DateFormat.getTimeFormat(getOwner().mSleepTime.getContext()).format(VLCApplication.sPlayerSleepTime.getTime());
if (text == null)
- text = "none set";
+ text = getOwner().getString(R.string.sleep_time_not_set);
getOwner().mSleepTime.setText(text);
break;
case DIALOG_LISTENER:
More information about the Android
mailing list