Disable single toolbar mode and update keyboard shortcuts versioning; remove unused 'zen-toggle-sidebar' shortcut

This commit is contained in:
mr. M
2024-11-27 16:52:23 +01:00
parent 15617953ab
commit 3bf7a477a6
3 changed files with 12 additions and 13 deletions

View File

@@ -121,7 +121,7 @@ pref('zen.view.sidebar-height-throttle', 200); // in ms
pref('zen.view.sidebar-expanded.max-width', 400);
pref('zen.view.show-bottom-border', false);
pref('zen.view.use-single-toolbar', true);
pref('zen.view.use-single-toolbar', false, locked);
#ifndef XP_MACOSX
pref('zen.view.hide-window-controls', true);

View File

@@ -100,6 +100,10 @@
& .titlebar-buttonbox {
align-items: center;
& .titlebar-button {
height: 100%;
}
}
}

View File

@@ -651,17 +651,6 @@ function zenGetDefaultShortcuts() {
'zen-web-panel-shortcut-toggle'
)
);
newShortcutList.push(
new KeyShortcut(
'zen-toggle-sidebar',
'B',
'',
ZEN_OTHER_SHORTCUTS_GROUP,
KeyShortcutModifiers.fromObject({ alt: true }),
'code:gZenVerticalTabsManager.toggleExpand()',
'zen-sidebar-shortcut-toggle'
)
);
// Split view
newShortcutList.push(
@@ -713,7 +702,7 @@ function zenGetDefaultShortcuts() {
}
class ZenKeyboardShortcutsVersioner {
static LATEST_KBS_VERSION = 3;
static LATEST_KBS_VERSION = 4;
constructor() {}
@@ -812,6 +801,12 @@ class ZenKeyboardShortcutsVersioner {
}
}
}
if (version < 4) {
// Migrate from 3 to 4
// In this new version, we are just removing the 'zen-toggle-sidebar' shortcut
// since it's not used anymore.
data = data.filter((shortcut) => shortcut.getID() != 'zen-toggle-sidebar');
}
return data;
}
}