Bug 1357785 accidentally omitted the flag on the interface itself. This patch makes thing consistent to prevent potential confusion in feature detection.
Differential Revision: https://phabricator.services.mozilla.com/D107742
Bug 1357785 accidentally omitted the flag on the interface itself. This patch makes thing consistent to prevent potential confusion in feature detection.
Differential Revision: https://phabricator.services.mozilla.com/D107742
For minimizing the previous patch changes, `scale`'s default value for
`screenX/Y` is treated as 1.0. It means that `screenX/Y` are device
pixels by default, but `offsetX/Y` are in CSS pixels by default. This
difference may make developers confused. Therefore, we should align the
default unit of them to `screenPixelsPerCSSPixel`. I.e., their default
unit becomes CSS pixels.
Differential Revision: https://phabricator.services.mozilla.com/D105929
For making the test framework/API change easier, such raw API shouldn't be
used directly. Therefore, this patch makes tests using it directly stop
using it and use `synthesizeNativeMouseEvent` instead.
However, this patch does not fix `browser_touch_event_iframes.js` because
it accesses the API from `ContentTask`. So, `EventUtils.js` isn't available
without larger change.
Note that this patch disables `test_bug596600.xhtml` because as I commented
in it, it's completely broken. It depends on the race of next native event
loop and `waitForTick`, and this patch changes the result of the race.
Differential Revision: https://phabricator.services.mozilla.com/D105765
Currently, it takes a raw native message value, but it makes JS content too
complicated. And on Linux, it cannot synthesize non-primary button events
because GDK has only button press and release messages which dont' include
mouse button information.
For solving these problems, this patch creates a new abstract native message
as `nsIWidget::NativeMouseMessage` and makes each widget converts it to
a platform native message.
Additionally, this patch adds an argument to make it possible its callers
to specify pressing or releasing mouse button with a DOM mouse button value.
Note that the following patch adds new argument to
`synthesizeNativeEventMouse*` for mochitests and which will be tested by
new tests.
Differential Revision: https://phabricator.services.mozilla.com/D105763
This was just a silly typo; I got the order of the ternary expression's options
backwards.
The mistake wasn't obvious from testing, because this function isn't always
invoked. In particular, it's not invoked if I print "https://example.org" in a
fresh profile, but it *is* invoked if I print "about:support" or other
browser-internal pages.
Differential Revision: https://phabricator.services.mozilla.com/D104354
Also, make sure that BFCachePreventionObserver does not fire events for
elements that are part of an anonymous native tree.
Differential Revision: https://phabricator.services.mozilla.com/D103812
We keep mMedium in nsPresContext rather than just looking it up in the
browsing context because that's used quite more frequently.
Differential Revision: https://phabricator.services.mozilla.com/D103782
Asynchronous font loading occurs during scroll position tests, it resets
scroll positions to 0. So, this causes intermittent failures in such tests.
Disabling the async font loading under `layout/base/tests` may not be proper
solution because some layout tests may work perfectly even if global reflow
may occur.
Therefore, this patch moves 2 tests which check scroll position to under
`dom/events/test` and disabling the async font loading since the global reflow
shouldn't be related to the tests under `dom/events`.
Differential Revision: https://phabricator.services.mozilla.com/D103013
Some mochitests use `nsISelectionController` instead of synthesizing key since
`Home`, `End`, `PageUp` and `PageDown` didn't work as native key event.
Differential Revision: https://phabricator.services.mozilla.com/D102879
Without this the non-native theme fails the last assertion of the test.
I couldn't reproduce locally but the word that it's supposed to be
selected is very close to being out of the iframe viewport on my
machine, so it'd make sense if the new non-native theme, which has a bit
more padding, causes the word to move a bit further down.
I've confirmed this fixes the issue.
Differential Revision: https://phabricator.services.mozilla.com/D103317
Touches that land on a descendant of a clickable element should
not get retargeted to other nearby elements because the descendant
itself can react to those touch events.
Differential Revision: https://phabricator.services.mozilla.com/D102827
This patch ensures that the global print_to_filename pref is checked
when initializing print settings from prefs.
It also fixes a regression which was preventing the Linux system dialog
from correctly reading its printer-specific print_to_filename prefs.
Differential Revision: https://phabricator.services.mozilla.com/D98975
For now, this subtest (ab)uses a fuzzy-failure allowance, to annotate a piece
of the test as a known failure on Windows (for an issue tracked in
bug 1680838).
The fuzzy annotation needs a bit of an increase, apparently, per at least one
failure log on Bug 1682294. This commit makes that increase, to avoid
test-failure-spam.
Differential Revision: https://phabricator.services.mozilla.com/D100477
This patch doesn't change the behavior, but should improve the stability
and error handling of _selection_location_helper().
From the current intermittent pattern, `self.selection_rect_list(0)` can
fail sometimes. We set a retry limit of three times, and raise
exceptions with clearer message if we give up. Bug 1682382 tracks the
root cause behind this.
Differential Revision: https://phabricator.services.mozilla.com/D99288
And have it mirror in the parent process more automatically.
The docShellIsActive setter in the browser-custom-element side needs to
be there rather than in the usual DidSet() calls because the
AsyncTabSwitcher code relies on getting an exact amount of notifications
as response to that specific setter. Not pretty, but...
BrowserChild no longer sets IsActive() on the docshell itself for OOP
iframes. This fixes bug 1679521. PresShell activeness is used to
throttle rAF as well, which handles OOP iframes nicely as well.
Differential Revision: https://phabricator.services.mozilla.com/D96072
This patch also updates the bug link in the explanatory comment for this group
of known-fuzzy-on-Windows test failures. (Before this patch, the code-comment
for these fuzzy failures points at bug 1671036, but that bug has been closed
because a speculative potentially-helpful patch landed there. The speculative
patch didn't actually fix the issue, unfortunately, so I opened bug 1680838
which now tracks this category of known fuzzy test failures, and I'm updating
the comment to point there.)
Differential Revision: https://phabricator.services.mozilla.com/D98834
UPDATED
-------
layout/base/tests/test_bug629838.html
bug 629838
Make sure MozPaintCount and MozAfterPaint are in sync, even with empty transactions
Switch to a <div> and use CSS. MozPaintCount is otherwise largely untested.
layout/base/tests/test_mozPaintCount.html
bug 563864
Test MozPaintCount.
Switch to a <div> and use CSS.
REMOVED
-------
layout/base/tests/chrome/test_chrome_over_plugin.xhtml
Test that plugins are properly clipped wrt translucent chrome elements and not by translucent content elements.
Differential Revision: https://phabricator.services.mozilla.com/D95913
UPDATED
-------
layout/base/tests/test_bug629838.html
bug 629838
Make sure MozPaintCount and MozAfterPaint are in sync, even with empty transactions
Switch to a <div> and use CSS. MozPaintCount is otherwise largely untested.
layout/base/tests/test_mozPaintCount.html
bug 563864
Test MozPaintCount.
Switch to a <div> and use CSS.
REMOVED
-------
layout/base/tests/chrome/test_chrome_over_plugin.xhtml
Test that plugins are properly clipped wrt translucent chrome elements and not by translucent content elements.
Differential Revision: https://phabricator.services.mozilla.com/D95913
This method only is async in order to allow callers to wait for a process switch
triggered by the call to `loadURI` to be finished before resolving. With
DocumentChannel, we should never trigger a process switch eagerly like this
again, so we don't need any of the async behaviour here anymore.
This part is largely mechanical changes to tests, removing the `await` calls on
`loadURI`, and a follow-up part will remove the actual async logic from
`BrowserTestUtils.loadURI`.
Differential Revision: https://phabricator.services.mozilla.com/D94641
This patch adds a new checkbox to the print UI for two-sided printing.
The checkbox is only visible if the currently selected printer supports
two-sided printing.
Notable Changes:
- Add new section and checkbox for two-sided printing.
- Add new getter to settings proxy for supportsDuplex.
- Add new setter/getter to settings proxy for printDuplex.
- Add new test for no duplex with PDF printer.
- Add new test for toggle duplex in portrait orientation.
- Add new test for toggle duplex in landscape orientation.
- Add new test for toggle orientation with duplex checked.
- Correctly set duple mode in GTK print settings.
Depends on D94026
Differential Revision: https://phabricator.services.mozilla.com/D93621