Skip to content

Commit

Permalink
Move qr scanner permission toast into translatable string
Browse files Browse the repository at this point in the history
  • Loading branch information
robbi5 committed Jul 17, 2024
1 parent dd45917 commit daebd27
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ class SetupActivity : AppCompatActivity(), ZXingScannerView.ResultHandler {
}
checkPermission(Manifest.permission.WRITE_EXTERNAL_STORAGE, PERMISSIONS_REQUEST_WRITE_STORAGE)
} else {
Toast.makeText(this, "Please grant camera permission to use the QR Scanner", Toast.LENGTH_SHORT).show()
Toast.makeText(this, getString(R.string.setup_grant_camera_permission), Toast.LENGTH_SHORT).show()
}
return
}
Expand Down Expand Up @@ -229,7 +229,6 @@ class SetupActivity : AppCompatActivity(), ZXingScannerView.ResultHandler {
pdialog.dismiss()

val intent = Intent(this@SetupActivity, MainActivity::class.java)
intent.flags = Intent.FLAG_ACTIVITY_NEW_TASK.or(Intent.FLAG_ACTIVITY_TASK_ON_HOME)
startActivity(intent)
finish()
}
Expand Down
1 change: 1 addition & 0 deletions pretixscan/app/src/main/res/values-de/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -177,4 +177,5 @@
<string name="error_no_available_events">Es wurde kein gegenwärtiges oder zukünftiges Event gefunden. Bitte prüfen Sie das Datum und die Zugriffsrechte Ihrer Veranstaltungen.</string>
<string name="event_select_calendar">Kalender anzeigen</string>
<string name="action_label_ok">OK</string>
<string name="setup_grant_camera_permission">Bitte erteilen Sie die Kamera-Berechtigung für den QR-Code-Scanner</string>
</resources>
1 change: 1 addition & 0 deletions pretixscan/app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -176,4 +176,5 @@
<string name="currently_inside">currently attending</string>
<string name="error_no_available_events">No current or future event could be found. Please check the dates and access rights of your events.</string>
<string name="event_select_calendar">Show calendar</string>
<string name="setup_grant_camera_permission">Please grant camera permission to use the QR Scanner</string>
</resources>

0 comments on commit daebd27

Please sign in to comment.