Граф коммитов

3951 Коммитов

Автор SHA1 Сообщение Дата
Simon Giesecke c153cfe233 Bug 1674080 - Add some required includes to the bindings generator. r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D95147
2021-03-11 13:38:31 +00:00
Jonathan Kew ceb44d34d6 Bug 1664730 - Disable async font fallback when running mochitests, to avoid unpredictable extra reflows that can disrupt event-/timing-sensitive tests. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D107284
2021-03-10 12:26:52 +00:00
Simon Giesecke ad01a10a3b Bug 1634281 - Use nsTHashMap instead of nsDataHashtable. r=xpcom-reviewers,necko-reviewers,jgilbert,nika,valentin
Note that this patch only transforms the use of the nsDataHashtable type alias
to a directly equivalent use of nsTHashMap. It does not change the specification
of the hash key type to make use of the key class deduction that nsTHashMap
allows for in some cases. That can be done in a separate step, but requires more
attention.

Differential Revision: https://phabricator.services.mozilla.com/D106008
2021-03-10 10:47:47 +00:00
Masayuki Nakano 468bffc558 Bug 1429523 - Make IMEContentObserver ignore character data change notifications of invisible data nodes r=smaug
E.g., comment node is an invisible data node, and it's not handled by
`HTMLEditor` nor `ContentEventHandler`.  Therefore, `IMEContentObserver`
should ignore invisible data nodes, which are not derived from `dom::Text`.

Differential Revision: https://phabricator.services.mozilla.com/D107590
2021-03-09 23:57:56 +00:00
Simon Giesecke bc9766c354 Bug 1634281 - Use nsTHashMap for nsBaseHashtable/nsDataHashtable uses with RefPtr data type. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D105963
2021-03-09 11:39:36 +00:00
Emilio Cobos Álvarez f36c63a891 Bug 1684001 - Add a pref-based blocklist to control default deltaMode. r=masayuki
Depends on D107456

Differential Revision: https://phabricator.services.mozilla.com/D107457
2021-03-09 01:59:43 +00:00
Emilio Cobos Álvarez 94b828fd9f Bug 1675949 - Keep rounding to integer sizes. a=orange
CSSIntSize::FromAppUnits actually doesn't return a CSSIntSize, it
returns a CSSSize.

MANUAL PUSH: Rounding orange on win/macos on a CLOSED TREE.
2021-03-08 02:34:36 +01:00
Emilio Cobos Álvarez 757f7268c6 Bug 1675949 - Use a non-fixed value for pixel deltas. r=masayuki
Your call if you think this is worth it. Might need some test
adjustments.

Differential Revision: https://phabricator.services.mozilla.com/D107199
2021-03-08 00:24:04 +00:00
Kagami Sascha Rosylight a2323b59a0 Bug 1691515 - Add MOZ_KNOWN_LIVE member annotation r=andi
Differential Revision: https://phabricator.services.mozilla.com/D107321
2021-03-05 23:23:03 +00:00
Alexandru Michis 4cff4186cb Backed out changeset 2d9ef4afb05d (bug 1675949) for causing mochitest plain failures in test_dom_wheel_event.html
CLOSED TREE
2021-03-05 05:51:36 +02:00
Emilio Cobos Álvarez e1a48f33c9 Bug 1675949 - Use a non-fixed value for pixel deltas. r=masayuki
Your call if you think this is worth it. Might need some test
adjustments.

Differential Revision: https://phabricator.services.mozilla.com/D107199
2021-03-05 02:28:21 +00:00
Kagami Sascha Rosylight a9417a719e Bug 1360715 - Part 2: Modify instanceofs in tests to non-cross-context r=edgar
Differential Revision: https://phabricator.services.mozilla.com/D106662
2021-03-04 22:03:57 +00:00
Brindusan Cristian b926d96be6 Backed out 3 changesets (bug 1360715) for mochitest failures at test_WebCrypto.html. CLOSED TREE
Backed out changeset b4a14c42313d (bug 1360715)
Backed out changeset 0e4b1b65fcbe (bug 1360715)
Backed out changeset fb8b9841d82b (bug 1360715)
2021-03-04 21:15:16 +02:00
Kagami Sascha Rosylight 73ec445d30 Bug 1360715 - Part 2: Modify instanceofs in tests to non-cross-context r=edgar
Differential Revision: https://phabricator.services.mozilla.com/D106662
2021-03-04 15:05:26 +00:00
Simon Giesecke c6ace2f153 Bug 1673931 - Avoid including BindingDeclarations.h from header files. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D97612
2021-03-04 14:32:14 +00:00
Butkovits Atila 4a2aa0080e Merge mozilla-central to autoland. CLOSED TREE 2021-03-04 00:23:06 +02:00
Andreea Pavel 002023eb26 Merge autoland to mozilla-central a=merge 2021-03-03 23:49:23 +02:00
Micah Tigley 99ac1f352b Bug 1695402 - Support image-set() on the cursor property. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D106745
2021-03-03 18:34:46 +00:00
Csoregi Natalia de702c9eb1 Backed out changeset 78567f53575e (bug 1695402) for failures on test_css-properties-db.js. CLOSED TREE 2021-03-03 19:54:08 +02:00
Micah Tigley dee15c3162 Bug 1695402 - Support image-set() on the cursor property. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D106745
2021-03-03 16:34:39 +00:00
Sebastian Hengst 7916a12f4f Backed out 2 changesets (bug 1528289) for breaking navigation with clicks after user scrolled by clicking with middle mouse button. a=backout
Backed out changeset 33c7b633ada2 (bug 1528289)
Backed out changeset be5cf87707f9 (bug 1528289)
2021-03-03 14:29:12 +01:00
Simon Giesecke 4ff9d15889 Bug 1634281 - Use nsBaseHashtable::GetOrInsertNew where possible. r=xpcom-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D106491
2021-03-03 08:58:52 +00:00
Emilio Cobos Álvarez 8508ab62bb Bug 1694548 - Move devtools breakpoints out of mutation events. r=smaug,jdescottes
Use internal events which get fired for CSSOM changes, and in Shadow
DOM. This will also allow us to remove mutation events in the future.

Depends on D106273

Differential Revision: https://phabricator.services.mozilla.com/D106274
2021-03-02 18:57:31 +00:00
Emilio Cobos Álvarez 156a1feb88 Bug 1694548 - Rename Document.dontWarnAboutMutationEventsAndAllowSlowDOMMutations and other misc cleanup in Document. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D106273
2021-03-02 18:57:31 +00:00
Kagami Sascha Rosylight 57967895ca Bug 1648267 - Part 5: Add test for dragging by pen r=edgar
Differential Revision: https://phabricator.services.mozilla.com/D106051
2021-03-02 18:29:46 +00:00
Mihai Alexandru Michis fd8d19d660 Backed out 2 changesets (bug 1694548) on suspicion of causing dt crashes in nsINode::LastRelease.
CLOSED TREE

Backed out changeset c87745c8f28b (bug 1694548)
Backed out changeset 3faa9b27e4a5 (bug 1694548)
2021-03-02 18:46:18 +02:00
Emilio Cobos Álvarez d16bd56f10 Bug 1694548 - Move devtools breakpoints out of mutation events. r=smaug,jdescottes
Use internal events which get fired for CSSOM changes, and in Shadow
DOM. This will also allow us to remove mutation events in the future.

Depends on D106273

Differential Revision: https://phabricator.services.mozilla.com/D106274
2021-03-02 12:54:21 +00:00
Emilio Cobos Álvarez 9530285f69 Bug 1694548 - Rename Document.dontWarnAboutMutationEventsAndAllowSlowDOMMutations and other misc cleanup in Document. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D106273
2021-03-02 12:54:21 +00:00
Masayuki Nakano 77d74d9e73 Bug 1528289 - part 2: Dispatch same events on the web contents when autoscroll is canceled with a click r=Gijs,edgar
Chrome behaves like this:

1. When user starts autoscroll with a middle click, `mousedown` and `mouseup`
   are fired, but `auxclick` nor `paste` event is not fired.
2. When user ends autoscroll with a left click, only `mouseup` event is fired.
   I.e, `mousedown` nor `click` event is not fired.
3. When user ends autoscroll with a middle click, only `mouseup` event is fired.
   I.e., `mousedown`, `auxclick` nor `paste` events is not fired.
4. When user ends autoscroll with a right click, `mouseup` and `contextmenu`
   events are fired, but `mousedown` and `auxclick` events are not fired.

This patch emulates these Chrome's behavior as far as possible.  However,
unfortunately, we cannot do exactly same behavior without some big patches
because each widget (`nsWindow` or `nsChildView`) discards a mouse event
which rolled up a widget before dispatching it into the DOM.  Therefore,
for now, this patch does not fix the following issues:

1. `mousedown` event is not fired in content when clicking outside the
   autoscroller to close it except when pressing the secondary button or on any
   buttons on Linux.
2. `mouseup` event is not fired in content when clicking outside the
   autoscroller to close it except when pressing the primary button macOS.
3. `click` event and `auxclick` events are fired when clicking outside the
   autoscroller with the secondary button.

So, the middle button `click`/`auxclick` events and `paste` event which is
reported to the bug won't be fired with this patch.  I'll file follow up bugs.

Differential Revision: https://phabricator.services.mozilla.com/D104652
2021-03-01 22:57:07 +00:00
Masayuki Nakano 246163150b Bug 1528289 - part 1: Move selection at middle button down rather than middle button up r=edgar
Chrome and Safari move selection at middle button down and does not modify the
range at middle button up.  However, they handle middle button down with
`Shift` key is "continue selection".  So, we should handle selection in
nsIFrame when `mousedown` event for middle mouse button is fired, but ignore
multiple selection, drag and drop and maintaining selection for aligning the
behavior to the other browsers.

This patch splits `nsIFrame::HandlePress()` and calls new method which
moves selection from `nsIFrame::HandleEvent()` when middle button is pressed.
(Note that this patch does not check whether middle click paste is enabled
because Chrome moves selection even on Windows which Chrome always disable
middle click paste on.)

With this change, "paste" event target is changed.  Previously, we used target
of the preceding `mouseup` event, but we start to use the target of the
preceding `mousedown` event.

Note that even with this patch, we still behave differently from Chrome even
in the following cases:
- middle mouse button down in selected range, we collapse it, but Chrome keeps
  the selection.
- middle mouse button click in selected range, we dispatch "paste" event, but
  Chrome collapse selection and not dispatch "paste" event.
- middle mouse button down in selected range and up in different element,
  Chrome does not modify the range nor dispatch "paste" event.
- Shift + middle mouse button in editable `<table>` works as non-editable
  in Chrome, but our editor handles it with special path.  Therefore, we
  don't modify the range but dispatch "paste" event in the selected range.

Changing them requires bigger change and probably requires some other features'
behavior changes.  Therefore, we shouldn't touch these issues until they are
actually reported as web-compat issues.

Differential Revision: https://phabricator.services.mozilla.com/D103997
2021-03-01 22:57:06 +00:00
Karl Dubost 03ce35d7f1 Bug 1241602 - Adds telemetry for MozMousePixelScroll usage. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D106578
2021-03-01 22:35:37 +00:00
Karl Dubost 623e9ce777 Bug 1241602 - Adds telemetry for DOMMouseScroll usage. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D106413
2021-03-01 22:35:36 +00:00
Masayuki Nakano e2b7c9c6b0 Bug 1520263 - Make `tabbrowser` wait reply event for F7 key before toggling caret browsing mode r=smaug
Unfortunately, it seems that `F7` key handling in `tabbrowser.js` cannot
replaced with using XUL `<key>` element because it works with
`ShortcutUtils.getSystemActionForEvent` for mapping `F7` is a toggle key of
caret browsing mode.

Therefore, this patch exposes some raw information of `WidgetEvent` related
to cross process event propagation and makes `tabbrowser.js` check it and
request reply event if it's required.

So, when a remote content has focus, `tabbrowser.js` will do nothing for both
`keydown` and `keypress` of `F7` key with original events, then, will request
a reply event if its default is not prevented.  Finally, reply `F7` keypress
event will toggle caret browsing mode if the event is fired and not consumed.

Differential Revision: https://phabricator.services.mozilla.com/D106591
2021-02-27 03:02:23 +00:00
Simon Giesecke 9af107a839 Bug 1691913 - Rename nsBaseHashtable::Put to InsertOrUpdate. r=xpcom-reviewers,necko-reviewers,jgilbert,dragana,nika
This makes the naming more consistent with other functions called
Insert and/or Update. Also, it removes the ambiguity whether
Put expects that an entry already exists or not, in particular because
it differed from nsTHashtable::PutEntry in that regard.

Differential Revision: https://phabricator.services.mozilla.com/D105473
2021-02-26 09:11:46 +00:00
Simon Giesecke 4f75368dcb Bug 1691913 - Rename nsBaseHashtable::GetOrInsert(With) to LookupOrInsert(With). r=xpcom-reviewers,necko-reviewers,jgilbert,dragana,nika
The functions should be called "Lookup" rather than "Get" because they return
a DataType& (rather than UserDataType).

Differential Revision: https://phabricator.services.mozilla.com/D105472
2021-02-26 09:11:45 +00:00
Tom Schuster f490362655 Bug 1689836 - Improve clipboard.write error messages and check image decoding more. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D105114
2021-02-24 19:51:05 +00:00
Tim Nguyen 5ac084ec38 Bug 1694722 - Remove unreachable check in IsAccessKeyTarget. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D106296
2021-02-24 18:05:15 +00:00
Masayuki Nakano 1c60ca0e2c Bug 1691622 - part 12: Change the default unit of `screenX/Y` of `synthesizeNativeMouseEvent` from device pixels to CSS pixels r=smaug
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
2021-02-24 01:27:11 +00:00
Masayuki Nakano bc2a8bc131 Bug 1691622 - part 7: Merge `synthesizeNativeMouseMove*` with `synthesizeNativeMouseEvent*` r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D105761
2021-02-24 01:27:09 +00:00
Masayuki Nakano 44ff291cb4 Bug 1691622 - part 6: Merge `synthesizeNativeMouseClick*` with `synthesizeNativeMouseEvent*` r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D105760
2021-02-24 01:27:08 +00:00
Masayuki Nakano 613d02b00b Bug 1691622 - part 3: Make `synthesizeNativeMouseClick` take screenX/Y r=smaug
Some tests want to specify screen position directly.  Therefore, they should
have additional fields in the `Object` param to take offset in screen.

Differential Revision: https://phabricator.services.mozilla.com/D105757
2021-02-24 01:27:07 +00:00
Masayuki Nakano 7242445ca1 Bug 1691622 - part 1: Make `synthesizeNativeMouseClick` take an `Object` instead of multiple arguments for synthesizing events r=smaug
In these days, API should take an `Object` instead of multiple arguments
since the callers look like using "named" arguments and this allows to
add new optional arguments with changing not all callers.

This patch also changes similar API for APZ aware tests for keeping
consistent style for their users.

Differential Revision: https://phabricator.services.mozilla.com/D105755
2021-02-24 01:27:06 +00:00
Simon Giesecke d2caea36fa Bug 1691894 - Simplify uses of WithEntryHandle that only use OrInsert(With) by using GetOrInsertWith. r=xpcom-reviewers,necko-reviewers,jgilbert,nika
Differential Revision: https://phabricator.services.mozilla.com/D104676
2021-02-22 12:07:46 +00:00
Henri Sivonen 9d6d02b341 Bug 1663931 - Avoid moving focus when changing iframe remoteness. r=nika,mccr8
Differential Revision: https://phabricator.services.mozilla.com/D99215
2021-02-22 10:51:51 +00:00
Kagami Sascha Rosylight 275bd35501 Bug 1693683 - Make sure DND is disabled only on Windows r=edgar
Differential Revision: https://phabricator.services.mozilla.com/D105705
2021-02-19 17:52:25 +00:00
Simon Giesecke 661e25bf09 Bug 1692880 - Make Put accept DataType instead of wrapping UserDataType. r=xpcom-reviewers,necko-reviewers,nika
Differential Revision: https://phabricator.services.mozilla.com/D104850
2021-02-16 15:53:33 +00:00
Simon Giesecke 06738f2b86 Bug 1693003 - Remove redundant nullptr checks of return value of infallible new in dom/. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D105292
2021-02-16 15:52:10 +00:00
Gerald Squelart 2416d881e2 Bug 1691589 - Reduce reliance on GeckoProfiler.h when only labels (and maybe markers) are needed - r=necko-reviewers,geckoview-reviewers,sg,agi,florian
There are no code changes, only #include changes.
It was a fairly mechanical process: Search for all "AUTO_PROFILER_LABEL", and in each file, if only labels are used, convert "GeckoProfiler.h" into "ProfilerLabels.h" (or just add that last one where needed).
In some files, there were also some marker calls but no other profiler-related calls, in these cases "GeckoProfiler.h" was replaced with both "ProfilerLabels.h" and "ProfilerMarkers.h", which still helps in reducing the use of the all-encompassing "GeckoProfiler.h".

Differential Revision: https://phabricator.services.mozilla.com/D104588
2021-02-16 04:44:19 +00:00
Simon Giesecke 780a1636a9 Bug 1691894 - Replace several suboptimal uses of Put after Get by GetOrInsertWith or WithEntryHandle. r=xpcom-reviewers,necko-reviewers,kmag,valentin,geckoview-reviewers,agi
Differential Revision: https://phabricator.services.mozilla.com/D104849
2021-02-15 15:12:17 +00:00
smolnar 1afbbe67e1 Backed out 5 changesets (bug 1691894) for causing hazard failures in nsXULPrototypeCache. CLOSED TREE
Backed out changeset 22dc870ee609 (bug 1691894)
Backed out changeset 58c31e9d6ae3 (bug 1691894)
Backed out changeset 7483e84149d8 (bug 1691894)
Backed out changeset f977d6cfa973 (bug 1691894)
Backed out changeset db4503476f34 (bug 1691894)
2021-02-15 16:43:23 +02:00