From 278214ef86053b661bbb2e9d660f353619a77354 Mon Sep 17 00:00:00 2001 From: Geonu Kang Date: Tue, 28 Jul 2015 18:29:57 +0900 Subject: [PATCH] Improve multi-device strings consistency Fixes #3830 Closes #3840 // FREEBIE --- AndroidManifest.xml | 2 +- res/layout/device_list_fragment.xml | 2 +- res/values/strings.xml | 22 +++++++++---------- .../securesms/DeviceListActivity.java | 8 +++---- .../securesms/DeviceListItem.java | 2 +- .../securesms/DeviceProvisioningActivity.java | 2 +- 6 files changed, 19 insertions(+), 19 deletions(-) diff --git a/AndroidManifest.xml b/AndroidManifest.xml index 0bdc2c5df8..5cca299f86 100644 --- a/AndroidManifest.xml +++ b/AndroidManifest.xml @@ -235,7 +235,7 @@ android:configChanges="touchscreen|keyboard|keyboardHidden|orientation|screenLayout|screenSize"/> + android:text="@string/device_list_fragment__no_devices_linked"/> %d min - Disconnect \'%s\'? - By disconnecting this device, it will no longer be able to send or receive messages. + Unlink \'%s\'? + By unlinking this device, it will no longer be able to send or receive messages. Network connection failed... Try again - Disconnecting device... - Disconnecting device + Unlinking device... + Unlinking device Network failed! Unnamed device - Created %s + Linked %s Last active %s @@ -293,13 +293,13 @@ - Read all your messages \n- Send messages in your name - Adding device - Adding new device... - Device added! + Linking device + Linking new device... + Device linked! No device found. Network error. Invalid QR code. - Sorry, you have too many devices registered already, try removing some... + Sorry, you have too many devices linked already, try removing some... Enter passphrase @@ -549,7 +549,7 @@ Search - No devices paired... + No devices linked... Could not grab logs from your device. You can still use ADB to get debug logs instead. @@ -737,7 +737,7 @@ All images All images with %1$s Message Details - Manage paired devices + Manage linked devices Import / export diff --git a/src/org/thoughtcrime/securesms/DeviceListActivity.java b/src/org/thoughtcrime/securesms/DeviceListActivity.java index 0f20d1a415..70605144e3 100644 --- a/src/org/thoughtcrime/securesms/DeviceListActivity.java +++ b/src/org/thoughtcrime/securesms/DeviceListActivity.java @@ -137,8 +137,8 @@ public class DeviceListActivity extends PassphraseRequiredActionBarActivity { final long deviceId = ((DeviceListItem)view).getDeviceId(); AlertDialogWrapper.Builder builder = new AlertDialogWrapper.Builder(getActivity()); - builder.setTitle(getActivity().getString(R.string.DeviceListActivity_disconnect_s, deviceName)); - builder.setMessage(R.string.DeviceListActivity_by_disconnecting_this_device_it_will_no_longer_be_able_to_send_or_receive); + builder.setTitle(getActivity().getString(R.string.DeviceListActivity_unlink_s, deviceName)); + builder.setMessage(R.string.DeviceListActivity_by_unlinking_this_device_it_will_no_longer_be_able_to_send_or_receive); builder.setNegativeButton(android.R.string.cancel, null); builder.setPositiveButton(android.R.string.ok, new DialogInterface.OnClickListener() { @Override @@ -164,8 +164,8 @@ public class DeviceListActivity extends PassphraseRequiredActionBarActivity { private void handleDisconnectDevice(final long deviceId) { new ProgressDialogAsyncTask(getActivity(), - R.string.DeviceListActivity_disconnecting_device_no_ellipse, - R.string.DeviceListActivity_disconnecting_device) + R.string.DeviceListActivity_unlinking_device_no_ellipsis, + R.string.DeviceListActivity_unlinking_device) { @Override protected Void doInBackground(Void... params) { diff --git a/src/org/thoughtcrime/securesms/DeviceListItem.java b/src/org/thoughtcrime/securesms/DeviceListItem.java index 39b32f5bac..fe35005053 100644 --- a/src/org/thoughtcrime/securesms/DeviceListItem.java +++ b/src/org/thoughtcrime/securesms/DeviceListItem.java @@ -38,7 +38,7 @@ public class DeviceListItem extends LinearLayout { if (TextUtils.isEmpty(deviceInfo.getName())) this.name.setText(R.string.DeviceListItem_unnamed_device); else this.name.setText(deviceInfo.getName()); - this.created.setText(getContext().getString(R.string.DeviceListItem_created_s, + this.created.setText(getContext().getString(R.string.DeviceListItem_linked_s, DateUtils.getExtendedRelativeTimeSpanString(getContext(), Locale.getDefault(), deviceInfo.getCreated()))); diff --git a/src/org/thoughtcrime/securesms/DeviceProvisioningActivity.java b/src/org/thoughtcrime/securesms/DeviceProvisioningActivity.java index 39e0ea33ac..2d5799da3e 100644 --- a/src/org/thoughtcrime/securesms/DeviceProvisioningActivity.java +++ b/src/org/thoughtcrime/securesms/DeviceProvisioningActivity.java @@ -149,7 +149,7 @@ public class DeviceProvisioningActivity extends PassphraseRequiredActionBarActiv Toast.makeText(context, R.string.DeviceProvisioningActivity_content_progress_key_error, Toast.LENGTH_LONG).show(); break; case LIMIT_EXCEEDED: - Toast.makeText(context, R.string.DeviceProvisioningActivity_sorry_you_have_too_many_devices_registered_already, Toast.LENGTH_LONG).show(); + Toast.makeText(context, R.string.DeviceProvisioningActivity_sorry_you_have_too_many_devices_linked_already, Toast.LENGTH_LONG).show(); break; } dialog.dismiss();