New string resources created by changing brand name.

This commit is contained in:
Onuray Sahin 2020-07-01 14:43:35 +03:00
parent 08710978c5
commit 7aa9f88ceb
26 changed files with 67 additions and 36 deletions

View file

@ -41,11 +41,11 @@ class TestFirebaseToken @Inject constructor(private val context: AppCompatActivi
val errorMsg = if (task.exception == null) "Unknown" else task.exception!!.localizedMessage
// Can't find where this constant is (not documented -or deprecated in docs- and all obfuscated)
if ("SERVICE_NOT_AVAILABLE".equals(errorMsg)) {
description = stringProvider.getString(R.string.settings_troubleshoot_test_fcm_failed_service_not_available, errorMsg)
description = stringProvider.getString(R.string.element_settings_troubleshoot_test_fcm_failed_service_not_available, errorMsg)
} else if ("TOO_MANY_REGISTRATIONS".equals(errorMsg)) {
description = stringProvider.getString(R.string.settings_troubleshoot_test_fcm_failed_too_many_registration, errorMsg)
description = stringProvider.getString(R.string.element_settings_troubleshoot_test_fcm_failed_too_many_registration, errorMsg)
} else if ("ACCOUNT_MISSING".equals(errorMsg)) {
description = stringProvider.getString(R.string.settings_troubleshoot_test_fcm_failed_account_missing, errorMsg)
description = stringProvider.getString(R.string.element_settings_troubleshoot_test_fcm_failed_account_missing, errorMsg)
quickFix = object : TroubleshootQuickFix(R.string.settings_troubleshoot_test_fcm_failed_account_missing_quick_fix) {
override fun doFix() {
startAddGoogleAccountIntent(context, NotificationTroubleshootTestManager.REQ_CODE_FIX)

View file

@ -48,7 +48,7 @@ class TestPlayServices @Inject constructor(private val context: AppCompatActivit
Timber.e("Play Services apk error $resultCode -> ${apiAvailability.getErrorString(resultCode)}.")
}
description = stringProvider.getString(R.string.settings_troubleshoot_test_play_services_failed, apiAvailability.getErrorString(resultCode))
description = stringProvider.getString(R.string.element_settings_troubleshoot_test_play_services_failed, apiAvailability.getErrorString(resultCode))
status = TestStatus.FAILED
}
}

View file

@ -112,11 +112,11 @@ class DefaultErrorFormatter @Inject constructor(
private fun identityServerError(identityServiceError: IdentityServiceError): String {
return stringProvider.getString(when (identityServiceError) {
IdentityServiceError.OutdatedIdentityServer -> R.string.identity_server_error_outdated_identity_server
IdentityServiceError.OutdatedIdentityServer -> R.string.element_identity_server_error_outdated_identity_server
IdentityServiceError.OutdatedHomeServer -> R.string.identity_server_error_outdated_home_server
IdentityServiceError.NoIdentityServerConfigured -> R.string.identity_server_error_no_identity_server_configured
IdentityServiceError.TermsNotSignedException -> R.string.identity_server_error_terms_not_signed
IdentityServiceError.BulkLookupSha256NotSupported -> R.string.identity_server_error_bulk_sha256_not_supported
IdentityServiceError.BulkLookupSha256NotSupported -> R.string.element_identity_server_error_bulk_sha256_not_supported
IdentityServiceError.BindingError -> R.string.identity_server_error_binding_error
IdentityServiceError.NoCurrentBindingError -> R.string.identity_server_error_no_current_binding_error
})

View file

@ -199,11 +199,11 @@ class VectorCallActivity : VectorBaseActivity(), CallControlsView.InteractionLis
.disposeOnDestroy()
if (callArgs.isVideoCall) {
if (checkPermissions(PERMISSIONS_FOR_VIDEO_IP_CALL, this, CAPTURE_PERMISSION_REQUEST_CODE, R.string.permissions_rationale_msg_camera_and_audio)) {
if (checkPermissions(PERMISSIONS_FOR_VIDEO_IP_CALL, this, CAPTURE_PERMISSION_REQUEST_CODE, R.string.element_permissions_rationale_msg_camera_and_audio)) {
start()
}
} else {
if (checkPermissions(PERMISSIONS_FOR_AUDIO_IP_CALL, this, CAPTURE_PERMISSION_REQUEST_CODE, R.string.permissions_rationale_msg_record_audio)) {
if (checkPermissions(PERMISSIONS_FOR_AUDIO_IP_CALL, this, CAPTURE_PERMISSION_REQUEST_CODE, R.string.element_permissions_rationale_msg_record_audio)) {
start()
}
}
@ -367,7 +367,7 @@ class VectorCallActivity : VectorBaseActivity(), CallControlsView.InteractionLis
// TODO ask to use default stun, etc...
AlertDialog
.Builder(this)
.setTitle(R.string.call_failed_no_connection)
.setTitle(R.string.element_call_failed_no_connection)
.setMessage(getString(R.string.call_failed_no_connection_description))
.setNegativeButton(R.string.ok) { _, _ ->
callViewModel.handle(VectorCallViewActions.EndCall)

View file

@ -131,7 +131,7 @@ class KeysBackupSetupActivity : SimpleFragmentActivity() {
if (checkPermissions(PERMISSIONS_FOR_WRITING_FILES,
this,
PERMISSION_REQUEST_CODE_EXPORT_KEYS,
R.string.permissions_rationale_msg_keys_backup_export)) {
R.string.element_permissions_rationale_msg_keys_backup_export)) {
ExportKeysDialog().show(this, object : ExportKeysDialog.ExportKeyDialogListener {
override fun onPassphrase(passphrase: String) {
showWaitingView()

View file

@ -192,7 +192,7 @@ class KeysBackupSetupStep2Fragment @Inject constructor() : VectorBaseFragment()
}
else -> {
// User has entered a passphrase but want to skip this step.
viewModel.passphraseError.value = context?.getString(R.string.keys_backup_passphrase_not_empty_error_message)
viewModel.passphraseError.value = context?.getString(R.string.element_keys_backup_passphrase_not_empty_error_message)
}
}
}

View file

@ -134,7 +134,7 @@ class KeysBackupSetupStep3Fragment @Inject constructor() : VectorBaseFragment()
PERMISSIONS_FOR_WRITING_FILES,
this,
PERMISSION_REQUEST_CODE_EXPORT_KEYS,
R.string.permissions_rationale_msg_keys_backup_export
R.string.element_permissions_rationale_msg_keys_backup_export
)
if (permissionsChecked) {
exportRecoveryKeyToFile(recoveryKey)

View file

@ -105,7 +105,7 @@ class SetIdentityServerViewModel @AssistedInject constructor(
} catch (failure: Throwable) {
when {
failure is IdentityServiceError.OutdatedIdentityServer ->
_viewEvents.post(SetIdentityServerViewEvents.Failure(R.string.identity_server_error_outdated_identity_server, isDefault))
_viewEvents.post(SetIdentityServerViewEvents.Failure(R.string.element_identity_server_error_outdated_identity_server, isDefault))
failure is Failure.NetworkConnection && failure.ioException is UnknownHostException ->
_viewEvents.post(SetIdentityServerViewEvents.Failure(R.string.settings_discovery_bad_identity_server, isDefault))
else ->

View file

@ -563,14 +563,14 @@ class RoomDetailFragment @Inject constructor(
if (isVideoCall) {
if (checkPermissions(PERMISSIONS_FOR_VIDEO_IP_CALL,
this, VIDEO_CALL_PERMISSION_REQUEST_CODE,
R.string.permissions_rationale_msg_camera_and_audio)) {
R.string.element_permissions_rationale_msg_camera_and_audio)) {
roomDetailViewModel.pendingAction = null
roomDetailViewModel.handle(startCallAction)
}
} else {
if (checkPermissions(PERMISSIONS_FOR_AUDIO_IP_CALL,
this, AUDIO_CALL_PERMISSION_REQUEST_CODE,
R.string.permissions_rationale_msg_record_audio)) {
R.string.element_permissions_rationale_msg_record_audio)) {
roomDetailViewModel.pendingAction = null
roomDetailViewModel.handle(startCallAction)
}

View file

@ -1032,7 +1032,7 @@ class RoomDetailViewModel @AssistedInject constructor(
// Check if this request is still active and handled by me
room.getTimeLineEvent(action.eventId)?.let {
session.cryptoService().reRequestRoomKeyForEvent(it.root)
_viewEvents.post(RoomDetailViewEvents.ShowMessage(stringProvider.getString(R.string.e2e_re_request_encryption_key_dialog_content)))
_viewEvents.post(RoomDetailViewEvents.ShowMessage(stringProvider.getString(R.string.element_e2e_re_request_encryption_key_dialog_content)))
}
}

View file

@ -58,9 +58,9 @@ class DefaultItemFactory @Inject constructor(private val avatarSizeProvider: Ava
callback: TimelineEventController.Callback?,
throwable: Throwable? = null): DefaultItem {
val text = if (throwable == null) {
stringProvider.getString(R.string.rendering_event_error_type_of_event_not_handled, event.root.getClearType())
stringProvider.getString(R.string.element_rendering_event_error_type_of_event_not_handled, event.root.getClearType())
} else {
stringProvider.getString(R.string.rendering_event_error_exception, event.root.eventId)
stringProvider.getString(R.string.element_rendering_event_error_exception, event.root.eventId)
}
val informationData = informationDataFactory.create(event, null)
return create(text, informationData, highlight, callback)

View file

@ -115,7 +115,7 @@ class LoginFragment @Inject constructor() : AbstractLoginFragment() {
}
if (error == 0) {
loginViewModel.handle(LoginAction.LoginOrRegister(login, password, getString(R.string.login_mobile_device_riotx)))
loginViewModel.handle(LoginAction.LoginOrRegister(login, password, getString(R.string.element_login_mobile_device_riotx)))
}
}

View file

@ -68,7 +68,7 @@ class LoginServerUrlFormFragment @Inject constructor() : AbstractLoginFragment()
loginServerUrlFormText.text = getString(R.string.login_server_url_form_modular_text)
loginServerUrlFormLearnMore.isVisible = true
loginServerUrlFormHomeServerUrlTil.hint = getText(R.string.login_server_url_form_modular_hint)
loginServerUrlFormNotice.text = getString(R.string.login_server_url_form_modular_notice)
loginServerUrlFormNotice.text = getString(R.string.element_login_server_url_form_modular_notice)
}
ServerType.Other -> {
loginServerUrlFormIcon.isVisible = false
@ -76,7 +76,7 @@ class LoginServerUrlFormFragment @Inject constructor() : AbstractLoginFragment()
loginServerUrlFormText.text = getString(R.string.login_connect_to_a_custom_server)
loginServerUrlFormLearnMore.isVisible = false
loginServerUrlFormHomeServerUrlTil.hint = getText(R.string.login_server_url_form_other_hint)
loginServerUrlFormNotice.text = getString(R.string.login_server_url_form_other_notice)
loginServerUrlFormNotice.text = getString(R.string.element_login_server_url_form_other_notice)
}
else -> error("This fragment should not be displayed in matrix.org mode")
}

View file

@ -58,7 +58,7 @@ class RoomPreviewNoPreviewFragment @Inject constructor(
roomPreviewNoPreviewTopic.setTextOrHide(roomPreviewData.topic)
if (roomPreviewData.worldReadable) {
roomPreviewNoPreviewLabel.setText(R.string.room_preview_world_readable_room_not_supported_yet)
roomPreviewNoPreviewLabel.setText(R.string.element_room_preview_world_readable_room_not_supported_yet)
} else {
roomPreviewNoPreviewLabel.setText(R.string.room_preview_no_preview)
}

View file

@ -187,7 +187,7 @@ class VectorSettingsSecurityPrivacyFragment @Inject constructor(
if (checkPermissions(PERMISSIONS_FOR_WRITING_FILES,
this,
PERMISSION_REQUEST_CODE_EXPORT_KEYS,
R.string.permissions_rationale_msg_keys_backup_export)) {
R.string.element_permissions_rationale_msg_keys_backup_export)) {
activity?.let { activity ->
ExportKeysDialog().show(activity, object : ExportKeysDialog.ExportKeyDialogListener {
override fun onPassphrase(passphrase: String) {

View file

@ -39,7 +39,7 @@ class TestDeviceSettings @Inject constructor(private val vectorPreferences: Vect
manager?.retry()
}
}
description = stringProvider.getString(R.string.settings_troubleshoot_test_device_settings_failed)
description = stringProvider.getString(R.string.element_settings_troubleshoot_test_device_settings_failed)
status = TestStatus.FAILED
}
}

View file

@ -73,7 +73,7 @@ class SoftLogoutActivity : LoginActivity() {
// And inform the user
showError(getString(
R.string.soft_logout_sso_not_same_user_error,
R.string.element_soft_logout_sso_not_same_user_error,
softLogoutViewEvents.currentUserId,
softLogoutViewEvents.newUserId)
)

View file

@ -39,7 +39,7 @@
android:layout_marginStart="24dp"
android:layout_marginTop="21dp"
android:layout_marginEnd="24dp"
android:text="@string/alpha_disclaimer_content_line_1"
android:text="@string/element_alpha_disclaimer_content_line_1"
android:textColor="?riotx_text_primary"
android:textSize="16sp" />

View file

@ -81,7 +81,7 @@
android:layout_marginTop="6dp"
android:gravity="start"
android:textAppearance="@style/TextAppearance.Vector.Login.Text.Small"
tools:text="@string/login_server_url_form_modular_notice" />
tools:text="@string/element_login_server_url_form_modular_notice" />
<com.google.android.material.button.MaterialButton
android:id="@+id/loginServerUrlFormSubmit"

View file

@ -57,7 +57,7 @@
app:layout_constraintHorizontal_bias="0"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/troubleshootTestTitle"
tools:text="@string/settings_troubleshoot_test_device_settings_failed"
tools:text="@string/element_settings_troubleshoot_test_device_settings_failed"
tools:visibility="visible" />
<com.google.android.material.button.MaterialButton

View file

@ -25,7 +25,7 @@
android:textColor="?attr/colorAccent"
android:textSize="14sp"
android:textStyle="italic"
tools:text="@string/rendering_event_error_type_of_event_not_handled" />
tools:text="@string/element_rendering_event_error_type_of_event_not_handled" />
</LinearLayout>

View file

@ -4,7 +4,7 @@
android:id="@+id/itemVerificationNoticeText"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:contentDescription="@string/use_other_session_content_description"
android:contentDescription="@string/element_use_other_session_content_description"
android:paddingStart="16dp"
android:paddingEnd="16dp"
android:paddingBottom="8dp">
@ -14,7 +14,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="start"
android:text="@string/use_latest_riot"
android:text="@string/element_use_latest_riot"
android:textColor="?riotx_text_primary"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
@ -52,7 +52,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:gravity="center"
android:text="@string/riot_desktop_web"
android:text="@string/element_riot_desktop_web"
android:textColor="?riotx_text_primary"
app:layout_constraintEnd_toEndOf="@id/monitorIcon"
app:layout_constraintStart_toStartOf="@id/monitorIcon"
@ -64,7 +64,7 @@
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:gravity="center"
android:text="@string/riot_ios_android"
android:text="@string/element_riot_ios_android"
android:textColor="?riotx_text_primary"
app:layout_constraintEnd_toEndOf="@id/smartphoneIcon"
app:layout_constraintStart_toStartOf="@id/smartphoneIcon"

View file

@ -2496,4 +2496,35 @@ Not all features in Riot are implemented in RiotX yet. Main missing (and coming
<string name="save_your_security_key_title">Save your Security Key</string>
<string name="save_your_security_key_notice">Store your Security Key somewhere safe, like a password manager or a safe.</string>
<!-- Element (Rebranding) -->
<string name="element_call_failed_no_connection">Element Call Failed</string>
<string name="element_e2e_re_request_encryption_key_dialog_content">Please launch Element on another device that can decrypt the message so it can send the keys to this session.</string>
<string name="element_settings_call_ringtone_use_riot_ringtone">Use default Element ringtone for incoming calls</string>
<string name="element_permissions_rationale_msg_record_audio">Element needs permission to access your microphone to perform audio calls.</string>
<string name="element_permissions_rationale_msg_camera_and_audio">Element needs permission to access your camera and your microphone to perform video calls.\n\nPlease allow access on the next pop-ups to be able to make the call.</string>
<string name="element_settings_troubleshoot_test_device_settings_failed">Notifications are not enabled for this session.\nPlease check the Element settings.</string>
<string name="element_settings_troubleshoot_test_play_services_failed">Element uses Google Play Services to deliver push messages but it doesnt seem to be configured correctly:\n%1$s</string>
<string name="element_settings_troubleshoot_test_fcm_failed_too_many_registration">[%1$s]\nThis error is out of control of Element and according to Google, this error indicates that the device has too many apps registered with FCM. The error only occurs in cases where there are extreme numbers of apps, so it should not affect the average user.</string>
<string name="element_settings_troubleshoot_test_fcm_failed_service_not_available">[%1$s]\nThis error is out of control of Element. It can occur for several reasons. Maybe it will work if you retry later, you can also check that Google Play Service is not restricted in data usage in the system settings, or that your device clock is correct, or it can happen on custom ROM.</string>
<string name="element_settings_troubleshoot_test_fcm_failed_account_missing">[%1$s]\nThis error is out of control of Element. There is no Google account on the phone. Please open the account manager and add a Google account.</string>
<string name="element_settings_troubleshoot_test_bg_restricted_success">Background restrictions are disabled for Element. This test should be run using mobile data (no WIFI).\n%1$s</string>
<string name="element_settings_opt_in_of_analytics_summary">Element collects anonymous analytics to allow us to improve the application.</string>
<string name="element_keys_backup_passphrase_not_empty_error_message">Please delete the passphrase if you want Element to generate a recovery key.</string>
<string name="element_room_preview_world_readable_room_not_supported_yet">"The preview of world-readable room is not supported yet in Element"</string>
<string name="element_alpha_disclaimer_content_line_1">"While Element is in early development, some features may be missing and you may experience bugs."</string>
<string name="element_permissions_rationale_msg_keys_backup_export">Element needs permission to save your E2E keys on disk.\n\nPlease allow access on the next pop-up to be able to export your keys manually.</string>
<string name="element_login_server_url_form_modular_notice">Enter the address of the Modular Element or Server you want to use</string>
<string name="element_login_server_url_form_other_notice">Enter the address of a server or a Element you want to connect to</string>
<string name="element_soft_logout_sso_not_same_user_error">The current session is for user %1$s and you provide credentials for user %2$s. This is not supported by Element.\nPlease first clear data, then sign in again on another account.</string>
<string name="element_settings_developer_mode_fail_fast_summary">Element may crash more often when an unexpected error occurs</string>
<string name="element_rendering_event_error_type_of_event_not_handled">"Element does not handle events of type '%1$s'"</string>
<string name="element_rendering_event_error_exception">"Element encountered an issue when rendering content of event with id '%1$s'"</string>
<string name="element_login_mobile_device_riotx">Element Android</string>
<string name="element_use_other_session_content_description">Use the latest Element on your other devices, Element Web, Element Desktop, Element iOS, Element for Android, or another cross-signing capable Matrix client</string>
<string name="element_riot_desktop_web">Element Web\nElement Desktop</string>
<string name="element_riot_ios_android">Element iOS\nElement for Android</string>
<string name="element_use_latest_riot">Use the latest Element on your other devices:</string>
<string name="element_identity_server_error_outdated_identity_server">This identity server is outdated. Element support only API V2.</string>
<string name="element_identity_server_error_bulk_sha256_not_supported">For your privacy, Element only supports sending hashed user emails and phone number.</string>
</resources>

View file

@ -27,7 +27,7 @@
android:defaultValue="false"
android:dependency="SETTINGS_DEVELOPER_MODE_PREFERENCE_KEY"
android:key="SETTINGS_DEVELOPER_MODE_FAIL_FAST_PREFERENCE_KEY"
android:summary="@string/settings_developer_mode_fail_fast_summary"
android:summary="@string/element_settings_developer_mode_fail_fast_summary"
android:title="@string/settings_developer_mode_fail_fast_title" />
</im.vector.riotx.core.preference.VectorPreferenceCategory>

View file

@ -77,7 +77,7 @@
<im.vector.riotx.core.preference.VectorSwitchPreference
android:defaultValue="false"
android:key="SETTINGS_USE_ANALYTICS_KEY"
android:summary="@string/settings_opt_in_of_analytics_summary"
android:summary="@string/element_settings_opt_in_of_analytics_summary"
android:title="@string/settings_opt_in_of_analytics" />
</im.vector.riotx.core.preference.VectorPreferenceCategory>

View file

@ -9,7 +9,7 @@
android:defaultValue="true"
android:disableDependentsState="true"
android:key="SETTINGS_CALL_RINGTONE_USE_RIOT_PREFERENCE_KEY"
android:title="@string/settings_call_ringtone_use_riot_ringtone" />
android:title="@string/element_settings_call_ringtone_use_riot_ringtone" />
<im.vector.riotx.core.preference.VectorPreference
android:dependency="SETTINGS_CALL_RINGTONE_USE_RIOT_PREFERENCE_KEY"