mirror of
https://github.com/SoPat712/videospeed.git
synced 2026-04-26 22:23:09 -04:00
fix: restore default keybinding population in options
This commit is contained in:
+5
-4
@@ -910,10 +910,6 @@ function restore_options() {
|
||||
document.querySelectorAll(".customs:not([id])").forEach((row) => row.remove());
|
||||
|
||||
storage.keyBindings.forEach((item) => {
|
||||
var fallbackKeyCode =
|
||||
item.action === "display"
|
||||
? storage.displayKeyCode || tcDefaults.displayKeyCode
|
||||
: undefined;
|
||||
var row = document.getElementById(item.action);
|
||||
var normalizedBinding = normalizeStoredBinding(item);
|
||||
|
||||
@@ -924,6 +920,11 @@ function restore_options() {
|
||||
|
||||
if (!row) return;
|
||||
|
||||
var keyInput = row.querySelector(".customKey");
|
||||
if (keyInput) {
|
||||
updateCustomShortcutInputText(keyInput, normalizedBinding || null);
|
||||
}
|
||||
|
||||
var valueInput = row.querySelector(".customValue");
|
||||
if (customActionsNoValues.includes(item.action)) {
|
||||
if (valueInput) {
|
||||
|
||||
Reference in New Issue
Block a user