Skip to content
Snippets Groups Projects
Commit 4d507500 authored by Geoffrey Métais's avatar Geoffrey Métais
Browse files

DB dump: extract hardcoded strings

parent 1a9feed0
No related branches found
No related tags found
No related merge requests found
Pipeline #8678 passed with stage
in 5 minutes and 40 seconds
......@@ -720,4 +720,6 @@
<string name="validation_delete_playlist_text">This action cannot be undone.</string>
<string name="display_in_list">Display in list</string>
<string name="display_in_grid">Display in grid</string>
<string name="dump_db_succes">Database dumped on internal storage root</string>
<string name="dump_db_failure">Failed to dump database</string>
</resources>
......@@ -111,12 +111,12 @@ class PreferencesAdvanced : BasePreferenceFragment(), SharedPreferences.OnShared
if (FileUtils.copyFile(db, File(AndroidDevices.EXTERNAL_PUBLIC_DIRECTORY + AbstractMedialibrary.VLC_MEDIA_DB_NAME)))
runOnMainThread(Runnable {
val ctx = context
if (ctx != null) Toast.makeText(ctx, "Database dumped on internal storage root", Toast.LENGTH_LONG).show()
if (ctx != null) Toast.makeText(ctx, getString(R.string.dump_db_succes), Toast.LENGTH_LONG).show()
})
else
runOnMainThread(Runnable {
val ctx = context
if (ctx != null) Toast.makeText(ctx, "Failed to dumped database", Toast.LENGTH_LONG).show()
if (ctx != null) Toast.makeText(ctx, getString(R.string.dump_db_failure), Toast.LENGTH_LONG).show()
})
}
if (Permissions.canWriteStorage())
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment