mirror of
https://github.com/zen-browser/components.git
synced 2025-07-07 23:59:59 +02:00
Always disable sidebar-expand.on-hover if compact mode is is enabled with hide-tabbar
This commit is contained in:
parent
5c9edb195a
commit
df8875bb0b
1 changed files with 9 additions and 1 deletions
|
@ -14,6 +14,7 @@ var gZenCompactModeManager = {
|
|||
|
||||
init() {
|
||||
Services.prefs.addObserver('zen.view.compact', this._updateEvent.bind(this));
|
||||
Services.prefs.addObserver('zen.view.sidebar-expanded.on-hover', this._disableTabsOnHoverIfConflict.bind(this));
|
||||
Services.prefs.addObserver('zen.tabs.vertical.right-side', this._updateSidebarIsOnRight.bind(this));
|
||||
|
||||
gZenUIManager.addPopupTrackingAttribute(this.sidebar);
|
||||
|
@ -109,7 +110,14 @@ var gZenCompactModeManager = {
|
|||
|
||||
_updateEvent() {
|
||||
this._evenListeners.forEach((callback) => callback());
|
||||
Services.prefs.setBoolPref('zen.view.sidebar-expanded.on-hover', false);
|
||||
this._disableTabsOnHoverIfConflict();
|
||||
},
|
||||
|
||||
_disableTabsOnHoverIfConflict() {
|
||||
if (Services.prefs.getBoolPref('zen.view.compact')
|
||||
&& Services.prefs.getBoolPref('zen.view.compact.hide-tabbar')) {
|
||||
Services.prefs.setBoolPref('zen.view.sidebar-expanded.on-hover', false);
|
||||
}
|
||||
},
|
||||
|
||||
toggle() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue