feat: extracting more strings, replacing link device strings using existing activities in case they change in future

This commit is contained in:
Harris 2021-06-16 16:14:06 +10:00
parent 5ce28f976b
commit b0dab208d2
2 changed files with 6 additions and 3 deletions

View File

@ -157,7 +157,7 @@ private class LinkDeviceActivityAdapter(private val activity: LinkDeviceActivity
1 -> {
val result = ScanQRCodeWrapperFragment()
result.delegate = activity
result.message = "Navigate to Settings → Recovery Phrase on your other device to show your QR code."
result.message = activity.getString(R.string.activity_link_device_qr_message)
result
}
else -> throw IllegalStateException()
@ -166,8 +166,8 @@ private class LinkDeviceActivityAdapter(private val activity: LinkDeviceActivity
override fun getPageTitle(index: Int): CharSequence {
return when (index) {
0 -> activity.getString(R.string.fragment_recovery_phrase_title)
1 -> activity.getString(R.string.activity_qr_code_view_scan_qr_code_tab_title)
0 -> activity.getString(R.string.activity_link_device_recovery_phrase)
1 -> activity.getString(R.string.activity_link_device_scan_qr_code)
else -> throw IllegalStateException()
}
}

View File

@ -831,6 +831,9 @@
<string name="activity_link_device_skip_prompt">This is taking a while, would you like to skip?</string>
<string name="activity_link_device_link_device">Link a Device</string>
<string name="activity_link_device_recovery_phrase">Recovery Phrase</string>
<string name="activity_link_device_scan_qr_code">Scan QR Code</string>
<string name="activity_link_device_qr_message">Navigate to Settings → Recovery Phrase on your other device to show your QR code.</string>
<string name="activity_join_public_chat_join_rooms">Or join one of these…</string>
<string name="activity_pn_mode_message_notifications">Message Notifications</string>