diff --git a/src/browser/components/urlbar/UrlbarInput-sys-mjs.patch b/src/browser/components/urlbar/UrlbarInput-sys-mjs.patch index 6af004d11..f761f121f 100644 --- a/src/browser/components/urlbar/UrlbarInput-sys-mjs.patch +++ b/src/browser/components/urlbar/UrlbarInput-sys-mjs.patch @@ -1,5 +1,5 @@ diff --git a/browser/components/urlbar/UrlbarInput.sys.mjs b/browser/components/urlbar/UrlbarInput.sys.mjs -index 4b69136aa31bfef3a1d3b57ad0c75fe07fa26be0..8d94bc2b7f3469258cb1a24888c5890eb83047e1 100644 +index 4b69136aa31bfef3a1d3b57ad0c75fe07fa26be0..66ef8de0d2a767376740ca57d75b5372cc11ed40 100644 --- a/browser/components/urlbar/UrlbarInput.sys.mjs +++ b/browser/components/urlbar/UrlbarInput.sys.mjs @@ -68,6 +68,13 @@ XPCOMUtils.defineLazyPreferenceGetter( @@ -208,7 +208,7 @@ index 4b69136aa31bfef3a1d3b57ad0c75fe07fa26be0..8d94bc2b7f3469258cb1a24888c5890e this.view.autoOpen({ event }); } else { if (this._untrimOnFocusAfterKeydown) { -@@ -4164,9 +4237,12 @@ export class UrlbarInput { +@@ -4164,9 +4237,16 @@ export class UrlbarInput { } _on_mousedown(event) { @@ -216,24 +216,28 @@ index 4b69136aa31bfef3a1d3b57ad0c75fe07fa26be0..8d94bc2b7f3469258cb1a24888c5890e + switch (event.zenOriginalTarget || event.currentTarget) { case this.textbox: { this._mousedownOnUrlbarDescendant = true; -+ if (event.type != "click") { ++ const isProbablyFloating = ++ (lazy.ZEN_URLBAR_BEHAVIOR == "floating-on-type" && ++ this.hasAttribute("breakout-extend") && !this.focusedViaMousedown) || ++ (lazy.ZEN_URLBAR_BEHAVIOR == "float") || this.window.gZenVerticalTabsManager._hasSetSingleToolbar; ++ if (event.type != "click" && isProbablyFloating || event.type == "click" && !isProbablyFloating) { + return true; + } if ( event.target != this.inputField && -@@ -4176,8 +4252,8 @@ export class UrlbarInput { - break; - } +@@ -4178,6 +4258,10 @@ export class UrlbarInput { -- this.focusedViaMousedown = !this.focused; -- this._preventClickSelectsAll = this.focused; -+ this.focusedViaMousedown = !(lazy.ZEN_URLBAR_BEHAVIOR === 'default' ? this.focused : this.hasAttribute("breakout-extend")); -+ this._preventClickSelectsAll = lazy.ZEN_URLBAR_BEHAVIOR === 'default' ? this.focused : this.hasAttribute("breakout-extend"); + this.focusedViaMousedown = !this.focused; + this._preventClickSelectsAll = this.focused; ++ if (isProbablyFloating) { ++ this.focusedViaMousedown = !this.hasAttribute("breakout-extend"); ++ this._preventClickSelectsAll = this.hasAttribute("breakout-extend"); ++ } // Keep the focus status, since the attribute may be changed // upon calling this.focus(). -@@ -4218,7 +4294,7 @@ export class UrlbarInput { +@@ -4218,7 +4302,7 @@ export class UrlbarInput { } // Don't close the view when clicking on a tab; we may want to keep the // view open on tab switch, and the TabSelect event arrived earlier. diff --git a/src/browser/themes/shared/zen-icons/icons.css b/src/browser/themes/shared/zen-icons/icons.css index 94071b63d..a07cdc43f 100644 --- a/src/browser/themes/shared/zen-icons/icons.css +++ b/src/browser/themes/shared/zen-icons/icons.css @@ -1097,7 +1097,7 @@ menuitem[id='placesContext_new:separator'] { } #alltabs-button { - list-style-image: url("chrome://browser/skin/tabs.svg") !important; + list-style-image: url('chrome://browser/skin/tabs.svg') !important; } :not(:not(menubar) > menu, #ContentSelectDropdown) diff --git a/src/zen/common/styles/zen-urlbar.css b/src/zen/common/styles/zen-urlbar.css index 8aa457a4a..5ea183380 100644 --- a/src/zen/common/styles/zen-urlbar.css +++ b/src/zen/common/styles/zen-urlbar.css @@ -95,10 +95,16 @@ position: relative; } -:root[zen-single-toolbar='true'] #urlbar:not([breakout-extend='true']) #identity-box { - margin-inline-end: 0 !important; - &.chromeUI:not([pageproxystate='invalid']) #identity-icon-box { - border-radius: 10px !important; +:root[zen-single-toolbar='true'] #urlbar:not([breakout-extend='true']) { + & #urlbar-input { + cursor: default; + } + + & #identity-box { + margin-inline-end: 0 !important; + &.chromeUI:not([pageproxystate='invalid']) #identity-icon-box { + border-radius: 10px !important; + } } }