ma1 pushed to branch tor-browser-115.11.0esr-13.0-1 at The Tor Project / Applications / Tor Browser
Commits:
-
e4ed3f35
by hackademix at 2024-05-09T17:49:50+02:00
1 changed file:
Changes:
... | ... | @@ -81,8 +81,18 @@ const OnionAuthPrompt = (function () { |
81 | 81 | );
|
82 | 82 | },
|
83 | 83 | |
84 | + _autoFocus(event) {
|
|
85 | + event.target.ownerGlobal.focus();
|
|
86 | + },
|
|
87 | + |
|
84 | 88 | _onPromptShowing(aWarningMessage) {
|
85 | 89 | let xulDoc = this._browser.ownerDocument;
|
90 | + |
|
91 | + // Force back focus: tor-browser#41856
|
|
92 | + (this._popupElem = xulDoc.getElementById(
|
|
93 | + "tor-clientauth-notification"
|
|
94 | + ))?.addEventListener("click", this._autoFocus);
|
|
95 | + |
|
86 | 96 | let descElem = xulDoc.getElementById("tor-clientauth-notification-desc");
|
87 | 97 | if (descElem) {
|
88 | 98 | // Handle replacement of the onion name within the localized
|
... | ... | @@ -153,6 +163,7 @@ const OnionAuthPrompt = (function () { |
153 | 163 | this._boundOnKeyFieldInput = undefined;
|
154 | 164 | }
|
155 | 165 | }
|
166 | + this._popupElem?.removeEventListener("click", this._autoFocus);
|
|
156 | 167 | },
|
157 | 168 | |
158 | 169 | _onKeyFieldKeyPress(aEvent) {
|