Merge pull request #2212 from agrajaghh/betterpicker_translateable

make summary of passphrase timeout translatable
This commit is contained in:
Moxie Marlinspike 2014-12-12 17:04:29 -08:00
commit 642334da1f
3 changed files with 4 additions and 2 deletions

View File

@ -47,7 +47,6 @@ dependencies {
exclude module: 'support-v4'
}
compile 'com.squareup.dagger:dagger:1.2.2'
compile 'com.doomonafireball.betterpickers:library:1.5.2'
compile ("com.doomonafireball.betterpickers:library:1.5.2") {
exclude group: 'com.android.support', module: 'support-v4'
}

View File

@ -42,6 +42,9 @@
<string name="ApplicationPreferencesActivity_incoming_sms">Incoming</string>
<string name="ApplicationPreferencesActivity_outgoing_sms">outgoing</string>
<!-- AppProtectionPreferenceFragment -->
<string name="AppProtectionPreferenceFragment_minutes">%d minutes</string>
<!-- DraftDatabase -->
<string name="DraftDatabase_Draft_image_snippet">(image)</string>
<string name="DraftDatabase_Draft_audio_snippet">(audio)</string>

View File

@ -69,7 +69,7 @@ public class AppProtectionPreferenceFragment extends PreferenceFragment {
private void initializeTimeoutSummary() {
int timeoutMinutes = TextSecurePreferences.getPassphraseTimeoutInterval(getActivity());
this.findPreference(TextSecurePreferences.PASSPHRASE_TIMEOUT_INTERVAL_PREF)
.setSummary(String.format("%d minutes", timeoutMinutes));
.setSummary(getString(R.string.AppProtectionPreferenceFragment_minutes, timeoutMinutes));
}
private class ChangePassphraseClickListener implements Preference.OnPreferenceClickListener {