Bootbox dialog improvements (#1192)

* Translate bootbox dialog buttons

This also isolates the bootbox dependency.

* Migrate delete playlist dialog from window.confirm to bootbox.confirm
This commit is contained in:
Pedro Galhardo 2022-06-23 02:27:58 +01:00 committed by GitHub
parent 0ca0b34ff0
commit 569f6c279a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 80 additions and 55 deletions

View file

@ -1407,7 +1407,7 @@
}
},
reinstallWidevineCDM() {
bootbox.confirm(app.getLz("settings.option.experimental.reinstallwidevine.confirm"), (ok) => {
app.confirm(app.getLz("settings.option.experimental.reinstallwidevine.confirm"), (ok) => {
if (ok) {
ipcRenderer.invoke("reinstall-widevine-cdm");
}
@ -1450,7 +1450,7 @@
toggleAudioContext: function () {
if (app.cfg.advanced.AudioContext === true) {
if (navigator.hardwareConcurrency < 6) {
bootbox.confirm(app.getLz("settings.warn.audio.enableAdvancedFunctionality.lowcores"), function (result) {
app.confirm(app.getLz("settings.warn.audio.enableAdvancedFunctionality.lowcores"), function (result) {
if (result) {
CiderAudio.init();
if (app.cfg.audio.normalization === true) {
@ -1497,7 +1497,7 @@
},
promptForRelaunch() {
bootbox.confirm(app.getLz('action.relaunch.confirm'), function (result) {
app.confirm(app.getLz('action.relaunch.confirm'), function (result) {
if (result) {
ipcRenderer.send('relaunchApp', '');
}