This commit does a couple of things:
- move whereToOpenLink and getRootEvent implementations into BrowserUtils,
so they can be used from the child process.
- forward callers in utilityOverlay.js to the BrowserUtils ones
(bug 1742889 will get rid of the forwarding and update all the callers;
we might be able to get this and bug 1739929 into beta if risk is low
enough, and touching a bunch of extra files really doesn't help with
that)
- move the lazy-load of BrowserUtils from browser.js to utilityOverlay.js
This is safe because everywhere that loads browser.js also loads
utilityOverlay.js. It's needed because there are some places that use
utilityOverlay.js but not browser.js, and so now they need access to
BrowserUtils.jsm.
- use whereToOpenLink to determine if we should avoid consuming the transient
user gesture activation in the child click handling code.
- add an automated test based on the testcase in the bug.
When working on this, I initially put the check using whereToOpenLink in
the toplevel of the function, and then when I ran places test to check that
I hadn't broken any places consumers of whereToOpenLink or getRootEvent,
realized that I had broken `browser_markPageAsFollowedLink.js`, because it
relies on "normal" (ie no modifier key, left button) link clicks making it
to ClickHandlerParent.jsm . I filed bug 1742894 about this. I've not tried
to fix that here, instead I've tried to ensure that paths through this
function are as untouched as possible while still fixing bug 1739929 and
bug 1742801.
Differential Revision: https://phabricator.services.mozilla.com/D132102
* Add jswindowactors for the Screenshots component, to facilitate communication between the UI (lives in the parent) and the content document.
* Fetch content document dimensions/offsets with e.g: `ScreenshotsUtils.fetchContentBounds(gBrowser.selectedBrowser)`.
Differential Revision: https://phabricator.services.mozilla.com/D129326
Also make some other context-menu code a lot more straight-forward, and
remove some enabledness checks now that shadow dom can't be disabled.
Differential Revision: https://phabricator.services.mozilla.com/D125487
Expose `Intl.DisplayNames` to `mozIntl`. The exposed `Intl.DisplayNames` version
supports date-time types, which have been removed from the spec proposal, but
may be re-enabled at some point in the future.
The existing `getDisplayNames` WebIDL function had to be renamed, because WebIDL
doesn't allow specify an attribute named `DisplayNames` and a separate function
called `getDisplayNames`.
Drive-by change:
- Removed an out-dated comment in "mozIMozIntlHelper.idl" which mentioned calling
`addDateTimeFormatConstructor` twice throws an error.
Differential Revision: https://phabricator.services.mozilla.com/D76114
Expose `Intl.DisplayNames` to `mozIntl`. The exposed `Intl.DisplayNames` version
supports date-time types, which have been removed from the spec proposal, but
may be re-enabled at some point in the future.
The existing `getDisplayNames` WebIDL function had to be renamed, because WebIDL
doesn't allow specify an attribute named `DisplayNames` and a separate function
called `getDisplayNames`.
Drive-by change:
- Removed an out-dated comment in "mozIMozIntlHelper.idl" which mentioned calling
`addDateTimeFormatConstructor` twice throws an error.
Differential Revision: https://phabricator.services.mozilla.com/D76114
Right now when using the OS/portal provided sharing dialog, the
selection in Firefox:
- does not serve any purpose as the sharing dialog is the only option
- unnecessarily add two more clicks and potentially confusion
Thus lets pre-select the OS sharing dialog in this case.
Differential Revision: https://phabricator.services.mozilla.com/D124332
CheckCurrentWord on content process causes sync IPC, so I would like to remove
this call on content process. New nsIEditorSpellChecker.suggest method can
avoid it.
Differential Revision: https://phabricator.services.mozilla.com/D119937