extract string resource

Signed-off-by: Felix Nüsse <felix.nuesse@t-online.de>
This commit is contained in:
Felix Nüsse 2022-11-22 16:31:15 +01:00
parent 8f1369cba2
commit ea2a1a9163
2 changed files with 3 additions and 1 deletions

View file

@ -80,9 +80,10 @@ class ShortcutUtil @Inject constructor(private val mContext: Context) {
MimeTypeUtil.getFileTypeIconId(file.mimeType, file.fileName)
)
}
val longLabel = mContext.getString(R.string.pin_shortcut_label, file.fileName)
val pinShortcutInfo = ShortcutInfoCompat.Builder(mContext, shortcutId)
.setShortLabel(file.fileName)
.setLongLabel("Open " + file.fileName)
.setLongLabel(longLabel)
.setIcon(icon)
.setIntent(intent)
.build()

View file

@ -1055,4 +1055,5 @@
<string name="e2e_not_yet_setup">E2E not yet setup</string>
<string name="error_file_actions">Error showing file actions</string>
<string name="pin_home">Pin to Home screen</string>
<string name="pin_shortcut_label">Open %1$s</string>
</resources>