From 9c1f7f1657a8347ea3c37612078f8fdc7507f2d0 Mon Sep 17 00:00:00 2001 From: haffenloher Date: Wed, 1 Feb 2017 03:50:48 +0100 Subject: [PATCH] Make VideoPlayer toast error message translatable Closes #6150 // FREEBIE --- res/values/strings.xml | 30 +++++++++++-------- .../securesms/video/VideoPlayer.java | 2 +- 2 files changed, 18 insertions(+), 14 deletions(-) diff --git a/res/values/strings.xml b/res/values/strings.xml index 068a3793dc..0b2b118b84 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -625,6 +625,11 @@ Signal is unlocked Lock with passphrase + + You + Failed to preview this image + Unsupported media type + %1$d new messages in %2$d conversations Most recent from: %1$s @@ -639,6 +644,14 @@ Media message Reply + + Manual MMS settings are required for your phone. + Enabled + Disabled + Not set + The text entered was not a valid URI + The text entered was not a valid host + Quick response unavailable when Signal is locked! Problem sending message! @@ -647,6 +660,9 @@ Signal New message + + Error playing video + The safety number for your conversation with %1$s has changed. This could either mean that someone is trying to intercept your communication, or that %2$s simply re-installed Signal. You may wish to verify your safety number with this contact. @@ -655,6 +671,7 @@ Tap to enable your video + Image Image @@ -846,14 +863,6 @@ VERIFY RESEND - - Manual MMS settings are required for your phone. - Enabled - Disabled - Not set - The text entered was not a valid URI - The text entered was not a valid host - %1$s joined the group. @@ -1283,11 +1292,6 @@ SHARE CLOSE - - You - Failed to preview this image - Unsupported media type - Save Forward diff --git a/src/org/thoughtcrime/securesms/video/VideoPlayer.java b/src/org/thoughtcrime/securesms/video/VideoPlayer.java index 47135bb5cb..bda1779fed 100644 --- a/src/org/thoughtcrime/securesms/video/VideoPlayer.java +++ b/src/org/thoughtcrime/securesms/video/VideoPlayer.java @@ -60,7 +60,7 @@ public class VideoPlayer extends FrameLayout { Log.w(TAG, "Playing video directly from non-local Uri..."); this.videoView.setVideoURI(videoSource.getUri()); } else { - Toast.makeText(getContext(), "Error playing video...", Toast.LENGTH_LONG).show(); + Toast.makeText(getContext(), getContext().getString(R.string.VideoPlayer_error_playing_video), Toast.LENGTH_LONG).show(); return; }