Remove hardcoded URL string
* Details on URLs in the credential management app preference should be translatable. * Remove hardcoded text and introduce strings. Manual testing * Download TestDPC and select 'Request to manage credentials'. * Select allow. * Go to Settings Credential management app preference and verify URL strings are displayed correctly. Bug: 170627997 Test: manual testing Change-Id: Iadff0c136064dabc3f77e30b46356126d657397f
This commit is contained in:
@@ -6522,6 +6522,11 @@
|
||||
<string name="certificate_management_app_description">Certificates installed by this app identify you to the apps and URLs below</string>
|
||||
<!-- Label for button to remove the credential management app [CHAR LIMIT=30] -->
|
||||
<string name="remove_credential_management_app">Remove</string>
|
||||
<!-- List item found in the credential management app's authentication policy [CHAR LIMIT=NONE] -->
|
||||
<plurals name="number_of_urls">
|
||||
<item quantity="one"><xliff:g id="number">%d</xliff:g> URL</item>
|
||||
<item quantity="other"><xliff:g id="number">%d</xliff:g> URLs</item>
|
||||
</plurals>
|
||||
|
||||
<!-- Sound settings screen, setting check box label -->
|
||||
<string name="emergency_tone_title">Emergency dialing signal</string>
|
||||
|
@@ -179,8 +179,8 @@ public class CredentialManagementAppAdapter extends RecyclerView.Adapter<Recycle
|
||||
}
|
||||
|
||||
private String getNumberOfUrlsText(Map<Uri, String> urisToAliases) {
|
||||
String url = urisToAliases.size() > 1 ? " URLs" : " URL";
|
||||
return urisToAliases.size() + url;
|
||||
return mContext.getResources().getQuantityString(R.plurals.number_of_urls,
|
||||
urisToAliases.size(), urisToAliases.size());
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user