parent
d98c4e318a
commit
af8b05d20c
@ -119,7 +119,7 @@ new class Action extends Handler {
|
||||
}
|
||||
try {
|
||||
await this.processResults(
|
||||
await Prefs.get("global-turbo"),
|
||||
true,
|
||||
await runContentJob(
|
||||
tab, "/bundles/content-gather.js", {
|
||||
type: "DTA:gather",
|
||||
@ -413,8 +413,24 @@ Bus.on("do-single", () => API.singleRegular(null));
|
||||
Bus.on("open-manager", () => openManager(true));
|
||||
Bus.on("open-prefs", () => openPrefs());
|
||||
|
||||
function adjustAction(globalTurbo: boolean) {
|
||||
action.setPopup({
|
||||
popup: globalTurbo ? "" : null
|
||||
});
|
||||
action.setIcon({
|
||||
path: globalTurbo ? {
|
||||
16: "/style/button-turbo.png",
|
||||
32: "/style/button-turbo@2x.png",
|
||||
} : null
|
||||
});
|
||||
}
|
||||
|
||||
(async function init() {
|
||||
await Prefs.set("last-run", new Date());
|
||||
Prefs.get("global-turbo", false).then(v => adjustAction(v));
|
||||
Prefs.on("global-turbo", (prefs, key, value) => {
|
||||
adjustAction(value);
|
||||
});
|
||||
await filters();
|
||||
await getManager();
|
||||
})().catch(ex => {
|
||||
|
@ -43,7 +43,7 @@
|
||||
<article id="tab-general" class="tab">
|
||||
<fieldset>
|
||||
<legend data-i18n="pref.ui">UI</legend>
|
||||
<!--<label><input type="checkbox" id="pref-global-turbo"> <span data-i18n="pref-global-turbo">Global turbo</span></label>-->
|
||||
<label><input type="checkbox" id="pref-global-turbo"> <span data-i18n="pref-global-turbo">Global turbo</span></label>
|
||||
<label><input type="checkbox" id="pref-finish-notification"> <span data-i18n="pref-finish-notification"></span></label>
|
||||
<div style="margin-top: 1em;">
|
||||
<button id="reset-confirmations" data-i18n="reset-confirmations"></button>
|
||||
|
@ -545,7 +545,7 @@ addEventListener("DOMContentLoaded", () => {
|
||||
localize(document.documentElement);
|
||||
|
||||
// General
|
||||
//new BoolPref("pref-global-turbo", "global-turbo");
|
||||
new BoolPref("pref-global-turbo", "global-turbo");
|
||||
new BoolPref("pref-queue-notification", "queue-notification");
|
||||
new BoolPref("pref-finish-notification", "finish-notification");
|
||||
new BoolPref("pref-tooltip", "tooltip");
|
||||
|
Loading…
x
Reference in New Issue
Block a user