mirror of
https://github.com/zen-browser/desktop.git
synced 2025-09-05 19:08:18 +00:00
Fixed urlbar hiding when entering on a composition state
This commit is contained in:
@@ -376,6 +376,7 @@ pref("browser.urlbar.quicksuggest.enabled", false);
|
||||
pref("browser.urlbar.suggest.quicksuggest.sponsored", false);
|
||||
pref("browser.urlbar.suggest.quicksuggest.nonsponsored", false);
|
||||
pref("browser.urlbar.groupLabels.enabled", false);
|
||||
pref("browser.urlbar.keepPanelOpenDuringImeComposition", true); // IMPORTANT: Fixes closing the urlbar when on some languages
|
||||
pref("browser.formfill.enable", false);
|
||||
pref("security.insecure_connection_text.enabled", true);
|
||||
pref("security.insecure_connection_text.pbmode.enabled", true);
|
||||
|
@@ -173,7 +173,7 @@ var gZenUIManager = {
|
||||
} else {
|
||||
this._lastSearch = gURLBar._untrimmedValue;
|
||||
}
|
||||
gURLBar.setURI(this._prevUrlbarLabel, false, false, false, true);
|
||||
gURLBar.setURI(this._prevUrlbarLabel, onSwitch, false, false, !onSwitch);
|
||||
gURLBar.handleRevert();
|
||||
if (gURLBar.focused) {
|
||||
gURLBar.view.close({ elementPicked: onSwitch });
|
||||
|
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/tabbrowser/content/tabbrowser.js b/browser/components/tabbrowser/content/tabbrowser.js
|
||||
index ff90a70bdad6c94ec4b90027ff102972d0eb28e5..838542e31112c7c3b5e9049da4a2cb6b1c975652 100644
|
||||
index ff90a70bdad6c94ec4b90027ff102972d0eb28e5..39cb6ceda6154609daa8f3b84c4931de6604534f 100644
|
||||
--- a/browser/components/tabbrowser/content/tabbrowser.js
|
||||
+++ b/browser/components/tabbrowser/content/tabbrowser.js
|
||||
@@ -406,11 +406,39 @@
|
||||
@@ -80,16 +80,16 @@ index ff90a70bdad6c94ec4b90027ff102972d0eb28e5..838542e31112c7c3b5e9049da4a2cb6b
|
||||
oldTab.updateLastAccessed();
|
||||
// if this is the foreground window, update the last-seen timestamps.
|
||||
if (this.ownerGlobal == BrowserWindowTracker.getTopWindow()) {
|
||||
@@ -1477,6 +1511,9 @@
|
||||
newBrowser &&
|
||||
gURLBar.getBrowserState(newBrowser).urlbarFocused &&
|
||||
gURLBar.focused;
|
||||
+ if (gURLBar._zenHandleUrlbarClose) {
|
||||
+ gURLBar._zenHandleUrlbarClose(true);
|
||||
+ }
|
||||
if (!keepFocusOnUrlBar) {
|
||||
// Clear focus so that _adjustFocusAfterTabSwitch can detect if
|
||||
// some element has been focused and respect that.
|
||||
@@ -1462,6 +1496,9 @@
|
||||
}
|
||||
|
||||
let activeEl = document.activeElement;
|
||||
+ if (gURLBar._zenHandleUrlbarClose) {
|
||||
+ gURLBar._zenHandleUrlbarClose(true);
|
||||
+ }
|
||||
// If focus is on the old tab, move it to the new tab.
|
||||
if (activeEl == oldTab) {
|
||||
newTab.focus();
|
||||
@@ -2387,7 +2424,7 @@
|
||||
|
||||
let panel = this.getPanel(browser);
|
||||
|
@@ -1,5 +1,5 @@
|
||||
diff --git a/browser/components/urlbar/UrlbarInput.sys.mjs b/browser/components/urlbar/UrlbarInput.sys.mjs
|
||||
index 50968dc04b527438acf30151f0c2e92f8b45097c..2948efd18fb1ee609695acd5b5b0211ce209ff1a 100644
|
||||
index 50968dc04b527438acf30151f0c2e92f8b45097c..ea9207399b205c84d1263a4de8a63b776e36eabd 100644
|
||||
--- a/browser/components/urlbar/UrlbarInput.sys.mjs
|
||||
+++ b/browser/components/urlbar/UrlbarInput.sys.mjs
|
||||
@@ -67,6 +67,13 @@ XPCOMUtils.defineLazyPreferenceGetter(
|
||||
@@ -52,7 +52,7 @@ index 50968dc04b527438acf30151f0c2e92f8b45097c..2948efd18fb1ee609695acd5b5b0211c
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1087,11 +1105,14 @@ export class UrlbarInput {
|
||||
@@ -1087,7 +1105,11 @@ export class UrlbarInput {
|
||||
}
|
||||
|
||||
if (!result.payload.providesSearchMode) {
|
||||
@@ -65,11 +65,7 @@ index 50968dc04b527438acf30151f0c2e92f8b45097c..2948efd18fb1ee609695acd5b5b0211c
|
||||
}
|
||||
|
||||
this.controller.recordSelectedResult(event, result);
|
||||
-
|
||||
if (isCanonized) {
|
||||
this.controller.engagementEvent.record(event, {
|
||||
result,
|
||||
@@ -2144,6 +2165,11 @@ export class UrlbarInput {
|
||||
@@ -2144,6 +2166,11 @@ export class UrlbarInput {
|
||||
|
||||
this.setAttribute("breakout-extend", "true");
|
||||
|
||||
@@ -81,7 +77,7 @@ index 50968dc04b527438acf30151f0c2e92f8b45097c..2948efd18fb1ee609695acd5b5b0211c
|
||||
// Enable the animation only after the first extend call to ensure it
|
||||
// doesn't run when opening a new window.
|
||||
if (!this.hasAttribute("breakout-extend-animate")) {
|
||||
@@ -2163,6 +2189,11 @@ export class UrlbarInput {
|
||||
@@ -2163,6 +2190,11 @@ export class UrlbarInput {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -93,7 +89,7 @@ index 50968dc04b527438acf30151f0c2e92f8b45097c..2948efd18fb1ee609695acd5b5b0211c
|
||||
this.removeAttribute("breakout-extend");
|
||||
this.#updateTextboxPosition();
|
||||
}
|
||||
@@ -3305,7 +3336,7 @@ export class UrlbarInput {
|
||||
@@ -3305,7 +3337,7 @@ export class UrlbarInput {
|
||||
} else {
|
||||
where = lazy.BrowserUtils.whereToOpenLink(event, false, false);
|
||||
}
|
||||
@@ -102,7 +98,7 @@ index 50968dc04b527438acf30151f0c2e92f8b45097c..2948efd18fb1ee609695acd5b5b0211c
|
||||
if (where == "current") {
|
||||
where = "tab";
|
||||
} else if (where == "tab") {
|
||||
@@ -3859,6 +3890,11 @@ export class UrlbarInput {
|
||||
@@ -3859,6 +3891,11 @@ export class UrlbarInput {
|
||||
}
|
||||
|
||||
_on_click(event) {
|
||||
@@ -114,7 +110,7 @@ index 50968dc04b527438acf30151f0c2e92f8b45097c..2948efd18fb1ee609695acd5b5b0211c
|
||||
if (
|
||||
event.target == this.inputField ||
|
||||
event.target == this._inputContainer ||
|
||||
@@ -3930,7 +3966,7 @@ export class UrlbarInput {
|
||||
@@ -3930,7 +3967,7 @@ export class UrlbarInput {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -123,7 +119,7 @@ index 50968dc04b527438acf30151f0c2e92f8b45097c..2948efd18fb1ee609695acd5b5b0211c
|
||||
this.view.autoOpen({ event });
|
||||
} else {
|
||||
if (this._untrimOnFocusAfterKeydown) {
|
||||
@@ -3970,9 +4006,12 @@ export class UrlbarInput {
|
||||
@@ -3970,9 +4007,12 @@ export class UrlbarInput {
|
||||
}
|
||||
|
||||
_on_mousedown(event) {
|
||||
@@ -137,7 +133,7 @@ index 50968dc04b527438acf30151f0c2e92f8b45097c..2948efd18fb1ee609695acd5b5b0211c
|
||||
|
||||
if (
|
||||
event.target != this.inputField &&
|
||||
@@ -3982,8 +4021,8 @@ export class UrlbarInput {
|
||||
@@ -3982,8 +4022,8 @@ export class UrlbarInput {
|
||||
break;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user