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

237 Коммитов

Автор SHA1 Сообщение Дата
Tom Ritter c4662925e4 Bug 1778510: Cut Event over to new Timer Design r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D156508
2022-11-29 13:34:21 +00:00
Butkovits Atila cb853b7f77 Backed out 33 changesets (bug 1778510) for causing build bustages at nsIGlobalObject.h. CLOSED TREE
Backed out changeset f2a53c9e497c
Backed out changeset 59350ca6f3f2 (bug 1778510)
Backed out changeset abbba7e72b57 (bug 1778510)
Backed out changeset 6cf7473afae8 (bug 1778510)
Backed out changeset 74fb5fed93ea (bug 1778510)
Backed out changeset 5b5dc70cdd0a (bug 1778510)
Backed out changeset ff93191cafd2 (bug 1778510)
Backed out changeset 39cc006b610c (bug 1778510)
Backed out changeset dfaef3ad17a9 (bug 1778510)
Backed out changeset 8fbabeb8244b (bug 1778510)
Backed out changeset 45051b62e3f1 (bug 1778510)
Backed out changeset 86c0923fd81f (bug 1778510)
Backed out changeset a49c0f69d519 (bug 1778510)
Backed out changeset cfad733d4aaf (bug 1778510)
Backed out changeset df6d0fe89d5b (bug 1778510)
Backed out changeset 704db76eab17 (bug 1778510)
Backed out changeset 0651c128e369 (bug 1778510)
Backed out changeset 1e650de647c0 (bug 1778510)
Backed out changeset fa15a3572741 (bug 1778510)
Backed out changeset 4ceffd409eae (bug 1778510)
Backed out changeset 47db43142c62 (bug 1778510)
Backed out changeset ebb21153aaac (bug 1778510)
Backed out changeset a87eaaec3f9c (bug 1778510)
Backed out changeset 43ad5ee21f79 (bug 1778510)
Backed out changeset 5f20af8e1263 (bug 1778510)
Backed out changeset b78576875db0 (bug 1778510)
Backed out changeset d801fdeac90b (bug 1778510)
Backed out changeset 5af032c628c0 (bug 1778510)
Backed out changeset 86aa59de11b4 (bug 1778510)
Backed out changeset 58642357a19c (bug 1778510)
Backed out changeset c575e824e291 (bug 1778510)
Backed out changeset 32a358de4843 (bug 1778510)
Backed out changeset 40e0708c01e7 (bug 1778510)
2022-11-28 23:14:52 +02:00
Tom Ritter 53b4389522 Bug 1778510: Cut Event over to new Timer Design r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D156508
2022-11-28 18:04:13 +00:00
Cosmin Sabou d245f666b9 Backed out 33 changesets (bug 1778510) for causing bp-hybrid bustages on nsIPrincipal.h. CLOSED TREE
Backed out changeset 282f589ede4a
Backed out changeset e23d03ba5a89 (bug 1778510)
Backed out changeset cbdb34cf7c8d (bug 1778510)
Backed out changeset d9a54521f3fb (bug 1778510)
Backed out changeset f5b7f8ce38b0 (bug 1778510)
Backed out changeset eb64607765a9 (bug 1778510)
Backed out changeset 18291e692834 (bug 1778510)
Backed out changeset bb71cc94a8be (bug 1778510)
Backed out changeset 507e84e1dafe (bug 1778510)
Backed out changeset 6d42e7a083ac (bug 1778510)
Backed out changeset 53799e6a46dd (bug 1778510)
Backed out changeset ff20d709839a (bug 1778510)
Backed out changeset 328d4d2df591 (bug 1778510)
Backed out changeset 9ba44fd8a440 (bug 1778510)
Backed out changeset eb1b7e30e519 (bug 1778510)
Backed out changeset c0927de6153b (bug 1778510)
Backed out changeset 02a306acd093 (bug 1778510)
Backed out changeset 2c5eecc4ad4c (bug 1778510)
Backed out changeset 38a9f45c9621 (bug 1778510)
Backed out changeset 35b7c7df62ce (bug 1778510)
Backed out changeset 187d71f42593 (bug 1778510)
Backed out changeset 450f4ccd6cd0 (bug 1778510)
Backed out changeset 915149e27da0 (bug 1778510)
Backed out changeset 9c6e85369f15 (bug 1778510)
Backed out changeset c6a9fe0ce713 (bug 1778510)
Backed out changeset a2f00462157e (bug 1778510)
Backed out changeset 5278e40b80c3 (bug 1778510)
Backed out changeset dba220581d93 (bug 1778510)
Backed out changeset 17a63044b0dc (bug 1778510)
Backed out changeset 68d607aaa121 (bug 1778510)
Backed out changeset e93004f91f6f (bug 1778510)
Backed out changeset 41d6d9f889e1 (bug 1778510)
Backed out changeset 28ac62019086 (bug 1778510)
2022-11-28 07:34:46 +02:00
Tom Ritter 736c82ff8a Bug 1778510: Cut Event over to new Timer Design r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D156508
2022-11-28 04:21:34 +00:00
Olli Pettay 93acdfad59 Bug 1777574, automate CC zone handling, r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D155084
2022-09-07 11:22:51 +00:00
Emilio Cobos Álvarez 2ee4fc0f24 Bug 1757929 - Remove a bunch of IPC headers from gfxFont and co. r=jfkthame,layout-reviewers
Removing the whole chromium IPC config is not possible because
gfxPlatformFontList uses base::*, but this should speed up builds a
little so seems worth landing regardless.

Differential Revision: https://phabricator.services.mozilla.com/D143371
2022-05-05 11:37:51 +00:00
Marian-Vasile Laza 3309e86b5d Backed out changeset 52db7558a4da (bug 1757929) for causing build bustages Unified_cpp_image0.obj. CLOSED TREE 2022-05-05 00:41:56 +03:00
Emilio Cobos Álvarez 335ea6af87 Bug 1757929 - Remove a bunch of IPC headers from gfxFont and co. r=jfkthame,layout-reviewers
Removing the whole chromium IPC config is not possible because
gfxPlatformFontList uses base::*, but this should speed up builds a
little so seems worth landing regardless.

Differential Revision: https://phabricator.services.mozilla.com/D143371
2022-05-04 16:41:43 +00:00
Mirko Brodesser de7882c7c1 Bug 1760807: encapsulate return type of `Event::GetScreenCoords` in a `Maybe<>`. r=edgar
It's clearer and makes using the method less error-prone.

Differential Revision: https://phabricator.services.mozilla.com/D141747
2022-03-23 09:19:03 +00:00
Nika Layzell 05dc5e0d76 Bug 1754037 - Part 3c: Automatically update all ParamTraits implementations, r=ipc-reviewers,media-playback-reviewers,bryce,mccr8
Automatically generated rewrites of all ParamTraits and IPDLParamTraits
implementations in-tree to use IPC::Message{Reader,Writer}.

Differential Revision: https://phabricator.services.mozilla.com/D140004
2022-03-04 15:39:41 +00:00
Emilio Cobos Álvarez 745394808b Bug 1753836 - Make Event.screenX/screenY return page CSS coordinates. r=smaug,jfkthame
We report window.screen coordinates in CSS space, so it makes sense to do
the same for screen-relative offsets. This requires some front-end fixes
incoming in following patches.

Differential Revision: https://phabricator.services.mozilla.com/D138035
2022-02-16 12:18:10 +00:00
smolnar 33c038ec0d Backed out 6 changesets (bug 1753836) for causing mochitest failures in test_event_screenXY_with_zoom. CLOSED TREE
Backed out changeset a572cbc0fac2 (bug 1753836)
Backed out changeset 371a495ff728 (bug 1753836)
Backed out changeset 774af76be463 (bug 1753836)
Backed out changeset faa8a8f2d40f (bug 1753836)
Backed out changeset 9209832ecffe (bug 1753836)
Backed out changeset db443ce0406d (bug 1753836)
2022-02-16 01:47:51 +02:00
Emilio Cobos Álvarez eb3997bacd Bug 1753836 - Make Event.screenX/screenY return page CSS coordinates. r=smaug,jfkthame
We report window.screen coordinates in CSS space, so it makes sense to do
the same for screen-relative offsets. This requires some front-end fixes
incoming in following patches.

Differential Revision: https://phabricator.services.mozilla.com/D138035
2022-02-15 22:25:03 +00:00
Emilio Cobos Álvarez fb38c597a4 Bug 1596852 - Handle parent-process <browser type=chrome> in JSWindowActors. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D132731
2021-12-10 22:34:10 +00:00
Cristian Tuns 7863a1ef75 Backed out changeset 6a408466ecb6 (bug 1731504) for causing bug 1739045 CLOSED TREE 2021-11-03 12:10:03 -04:00
Masayuki Nakano 4341d6fb0c Bug 1455514 - part 1: Add accessors and static helper methods to retrieve `nsINode` or its concrete classes from `EventTarget` r=smaug
Currently, checking whether an `EventTarget` is `nsINode` (or its concrete
classes) or not requires a QI, but it's expensive and used a lot while we
handle each event.  Therefore, it'd be nicer for creating a virtual method,
`EventTarget::IsNode()` and use it for the check.

If trying to convert `EventTarget` to a concrete class, it may require two
virtual method calls.  I'm not sure whether it's cheaper than a QI, but at
least, it won't depend on the UUID check order of `QueryInterface()` when
multiple interfaces are implemented.

Differential Revision: https://phabricator.services.mozilla.com/D129781
2021-11-02 13:03:43 +00:00
Olli Pettay 7938f41dae WIP: Bug 1731504, explicitly call capturing listeners before bubbling listeners at target r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D128956
2021-10-27 12:37:50 +00:00
Kagami Sascha Rosylight 0b5d4cebd4 Bug 1635018 - Part 1: Limit dragexit event to chrome on Nightly r=edgar,masayuki
Differential Revision: https://phabricator.services.mozilla.com/D121189
2021-08-05 14:33:38 +00:00
Sean Feng 22e7aa390f Bug 1710682 - Make Event::GetEventName returns a char16_t r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D114872
2021-05-11 20:11:01 +00:00
Edgar Chen c2c0ea7709 Bug 1672330 - Move pointer lock code to PointerLockManager; r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D101054
2021-01-27 16:38:29 +00:00
Dorel Luca b5c5a81751 Backed out changeset 4e317086de97 (bug 1672330) for Mochitest failures in dom/tests/mochitest/pointerlock/test_pointerlock_focus.html. CLOSED TREE 2021-01-27 14:05:29 +02:00
Edgar Chen b81855eeb2 Bug 1672330 - Move pointer lock code to PointerLockManager; r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D101054
2021-01-27 10:08:29 +00:00
Olli Pettay b6bb80bd47 Bug 1686716 - Calling event.preventDefault in drop event handler causes a crash after target iframe has been removed, r=masayuki
Outerwindow implements nsIScriptObjectPrincipal.

Differential Revision: https://phabricator.services.mozilla.com/D101774
2021-01-15 10:04:50 +00:00
Emilio Cobos Álvarez 5279ef0ebd Bug 1684973 - Return mouse offset coordinates in SVG relative to the SVG root. r=smaug
This matches other browsers. Needs a test, if the try server comes back
green.

Differential Revision: https://phabricator.services.mozilla.com/D100762
2021-01-05 15:44:28 +00:00
Sylvestre Ledru fde06f6d21 Bug 1674637 - Use nested namespaces in dom/ r=sg,andi
Also add some missing namespace qualifications

Done with:
./mach static-analysis check --checks="-*,modernize-concat-nested-namespaces" --fix dom/
./mach clang-format -p $(hg status dom/|grep ^M|awk '{print $2}')

Differential Revision: https://phabricator.services.mozilla.com/D95456
2020-11-04 17:04:01 +00:00
Butkovits Atila 964cca3198 Backed out changeset c0adbf7522dc (bug 1674637) for bustage on GMPParent.cpp. CLOSED TREE 2020-11-04 10:54:36 +02:00
Sylvestre Ledru 5f29324f60 Bug 1674637 - Use nested namespaces in dom/ r=sg,andi
Also add some missing namespace qualifications

Done with:
./mach static-analysis check --checks="-*,modernize-concat-nested-namespaces" --fix dom/
./mach clang-format -p $(hg status dom/|grep ^M|awk '{print $2}')

Differential Revision: https://phabricator.services.mozilla.com/D95456
2020-11-04 08:29:00 +00:00
Simon Giesecke cd8b8939b9 Bug 1648010 - Replace uses of NS_LITERAL_STRING/NS_LITERAL_CSTRING macros by _ns literals. r=geckoview-reviewers,jgilbert,agi,hsivonen,froydnj
Differential Revision: https://phabricator.services.mozilla.com/D80860
2020-07-01 08:29:29 +00:00
Emilio Cobos Álvarez 89958b377a Bug 1640605 - Remove IsInAnonymousSubtree / IsRootOfAnonymousSubtree. r=edgar
In favor of the NativeAnonymous versions which they forward to.

Done automatically with:

  rg -l 'IsInAnonymousSubtree' | xargs sed -i 's/IsInAnonymousSubtree/IsInNativeAnonymousSubtree/g'

And removing the function definitions afterwards.

Differential Revision: https://phabricator.services.mozilla.com/D76681
2020-05-25 11:43:51 +00:00
Timothy Nikkel c05c933851 Bug 1557160. Stop Event::GetScreenCoords from converting from visual to layout coords. r=botond
Screen coords are not layout coords.

Differential Revision: https://phabricator.services.mozilla.com/D74788
2020-05-12 04:53:37 +00:00
Botond Ballo 551a4602dc Bug 1556556 - Miscellaneous fixes related to event coordinate transformations. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D69639
2020-05-05 19:28:15 +00:00
Botond Ballo 173d001b86 Bug 1556556 - Propagate RelativeTo far and wide. r=kats,mattwoodrow
This "upgrades" various nsLayoutUtils functions which take as inputs
a set of coordinates and a frame that the coordinates are relative to,
to accept a RelativeTo object instead of a frame.

Most of the patch is just dumb propagation, but the few places where
we use an explicit ViewportType::Visual are important. There are
probably a few other places I've overlooked, but this seems to cover
the important ones that come up commonly.

There are undoubtedly other functions into which we can propagate
RelativeTo, in this patch I've propagated it as far as necessary
for my needs in this bug (mainly GetTransformToAncestor() and
GetEventCoordinatesRelativeTo()).

Differential Revision: https://phabricator.services.mozilla.com/D68919
2020-05-05 19:26:38 +00:00
Csoregi Natalia b073baab86 Backed out 30 changesets (bug 1556556, bug 1631568) for multiple mochitest failures. CLOSED TREE
Backed out changeset edd529f7a9c5 (bug 1631568)
Backed out changeset 1cc0881e244b (bug 1631568)
Backed out changeset ed3c1e85d5e3 (bug 1556556)
Backed out changeset 38ffc6215bbf (bug 1556556)
Backed out changeset 03c2c25d8023 (bug 1556556)
Backed out changeset 9c717eb067b8 (bug 1556556)
Backed out changeset 98e26bc98b85 (bug 1556556)
Backed out changeset 05a6a581e755 (bug 1556556)
Backed out changeset 867946cf05bb (bug 1556556)
Backed out changeset 20d72a334530 (bug 1556556)
Backed out changeset 2c62e61d9054 (bug 1556556)
Backed out changeset 62a223d057d2 (bug 1556556)
Backed out changeset 2c5d55a1f0b1 (bug 1556556)
Backed out changeset 700447945b4e (bug 1556556)
Backed out changeset 93190ae4f5ff (bug 1556556)
Backed out changeset a7bd34d961bb (bug 1556556)
Backed out changeset fccd1d3c7189 (bug 1556556)
Backed out changeset 24056e47183d (bug 1556556)
Backed out changeset 204881474cc1 (bug 1556556)
Backed out changeset 387320881876 (bug 1556556)
Backed out changeset be8f5eb58460 (bug 1556556)
Backed out changeset 629c58a9166b (bug 1556556)
Backed out changeset 4312b2b5dda8 (bug 1556556)
Backed out changeset d11dbf6403a5 (bug 1556556)
Backed out changeset 95c54c023779 (bug 1556556)
Backed out changeset 80fcb7e71188 (bug 1556556)
Backed out changeset d75a4ecb0d47 (bug 1556556)
Backed out changeset 903c4de34e7a (bug 1556556)
Backed out changeset f15334a3e803 (bug 1556556)
Backed out changeset 9553e99137ea (bug 1556556)
2020-04-28 12:43:11 +03:00
Botond Ballo 08aae3b474 Bug 1556556 - Miscellaneous fixes related to event coordinate transformations. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D69639
2020-04-28 01:42:26 +00:00
Botond Ballo 405c8807cd Bug 1556556 - Propagate RelativeTo far and wide. r=kats,mattwoodrow
This "upgrades" various nsLayoutUtils functions which take as inputs
a set of coordinates and a frame that the coordinates are relative to,
to accept a RelativeTo object instead of a frame.

Most of the patch is just dumb propagation, but the few places where
we use an explicit ViewportType::Visual are important. There are
probably a few other places I've overlooked, but this seems to cover
the important ones that come up commonly.

There are undoubtedly other functions into which we can propagate
RelativeTo, in this patch I've propagated it as far as necessary
for my needs in this bug (mainly GetTransformToAncestor() and
GetEventCoordinatesRelativeTo()).

Differential Revision: https://phabricator.services.mozilla.com/D68919
2020-04-28 01:40:35 +00:00
Tom Tung 3d9adc5e80 Bug 1586761 - P4 - Use new methods in dom/file and dom/events; r=baku
For the usecases in dom/file, I'm not so sure how to get the global at
callsites, so I let aIsSystemPrincipal and aCrossOriginIsolated to be false for
now.

Differential Revision: https://phabricator.services.mozilla.com/D63905

--HG--
extra : moz-landing-system : lando
2020-03-25 14:14:37 +00:00
Masayuki Nakano b4cc4486d4 Bug 1449831 - part 1: Add `InputEvent.getTargetRanges()` r=smaug
`InputEvent.getTargetRanges()` can be used only when event type is
`beforeinput`.  So, it may be used for feature detection of `beforeinput`
event because Chrome does not implement `onbeforeinput` event handler attribute.
Therefore, this patch makes it behind the pref for `beforeinput` event.

Differential Revision: https://phabricator.services.mozilla.com/D64728

--HG--
extra : moz-landing-system : lando
2020-03-02 07:39:38 +00:00
Boris Zbarsky 75124bdd98 Bug 1517588. Use nsIPrincipal::IsSystemPrincipal instead of nsContentUtils::IsSystemPrincipal r=bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D53067

--HG--
extra : moz-landing-system : lando
2019-12-05 04:44:32 +00:00
Boris Zbarsky 14c30e58d6 Bug 1578173 part 4. Switch event subclasses to constructor operations. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D45391

--HG--
extra : moz-landing-system : lando
2019-09-11 14:35:28 +00:00
Boris Zbarsky d5a8a4a595 Bug 1557793 part 3. Change the signatures of various nsContentUtils localization methods to play nicer with the new stringbundle API. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D34201

--HG--
extra : moz-landing-system : lando
2019-06-08 21:26:12 +00:00
Masayuki Nakano 663f37d827 Bug 1547618 - Make dom use mozilla::PresShell rather than via nsIPresShell r=smaug
Additionally, this patch makes `nsContentUtils::DispatchXULCommand()` because
it guarantees the lifetime of **only** `PresShell` in it.  So, we need to check
the lifetime of each argument at each caller here.

Differential Revision: https://phabricator.services.mozilla.com/D29199

--HG--
extra : moz-landing-system : lando
2019-04-30 01:35:30 +00:00
Henri Sivonen 95281be87c Bug 1532901 - Fix event.screenX and event.screenY inside out-of-process iframes. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D25582

--HG--
extra : moz-landing-system : lando
2019-04-09 10:26:31 +00:00
Masayuki Nakano 9165a150a1 Bug 1540930 - Make nsPresContext use mozilla::PresShell directly rather than via nsIPresShell r=emilio
`nsPresContext` should use `mozilla::PresShell` directly instead of
`nsIPresShell`.  This patch makes it.

Unfortunately, `nsPresContext` and `nsIFrame` have `PresShell()`.  Therefore,
we cannot use `PresShell*` in its methods so that this patch uses `mozilla::`
namespace prefix.

It might be better to rename them as `PresShellPtr()` in another bug.

Differential Revision: https://phabricator.services.mozilla.com/D25721

--HG--
extra : moz-landing-system : lando
2019-04-03 12:40:26 +00:00
Masayuki Nakano e705b3211c Bug 1540015 - part 1: Make Document.h stop including nsIPresShell.h r=smaug
If `Document::GetShell()` returns `PresShell*` rather than `nsIPresShell`, it's
a good step to deCOMTaminate `PresShell`.

This patch makes `Document.h` stop including `nsIPresShell.h` since
`nsIPresShell.h` includes `Document.h` indirectly and that causes bustage
when we make `Document::GetShell()` return `PresShell*`.

Differential Revision: https://phabricator.services.mozilla.com/D25332

--HG--
extra : moz-landing-system : lando
2019-03-29 15:11:04 +00:00
Dorel Luca 5a0fa68b78 Backed out 3 changesets (bug 1540015) for build bustage. CLOSED TREE
Backed out changeset 7b71c9da0214 (bug 1540015)
Backed out changeset 5723ddbc5c44 (bug 1540015)
Backed out changeset 9561d2c36fa5 (bug 1540015)
2019-03-29 16:14:26 +02:00
Masayuki Nakano 854606257b Bug 1540015 - part 1: Make Document.h stop including nsIPresShell.h r=smaug
If `Document::GetShell()` returns `PresShell*` rather than `nsIPresShell`, it's
a good step to deCOMTaminate `PresShell`.

This patch makes `Document.h` stop including `nsIPresShell.h` since
`nsIPresShell.h` includes `Document.h` indirectly and that causes bustage
when we make `Document::GetShell()` return `PresShell*`.

Differential Revision: https://phabricator.services.mozilla.com/D25332

--HG--
extra : moz-landing-system : lando
2019-03-29 12:12:20 +00:00
Josef Citrine dde7723c68 Bug 1485264 - Removed dom.event.highrestimestamp.enabled pref r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D21580

--HG--
extra : moz-landing-system : lando
2019-03-01 18:49:44 +00:00
Masayuki Nakano 6eadee9e6c Bug 998941 - part 2-1: Implement InputEvent.dataTransfer declared by Input Events r=smaug
InputEvent.dataTransfer is declared by Input Events Level 1 and Level 2 (i.e.,
not UI Events).  It's necessary for "beforeinput" event on contenteditable
elements because of with some InputEvent.inputType values on contenteditable,
InputEvent.dataTransfer is used instead of InputEvent.data.

According to the Chrome's behavior, if InputEvent.dataTransfer is created by
web apps, the DataTransfer object is mutable.  Otherwise, i.e., the event
represents user input, the DataTransfer object is read only.  We should follow
this behavior.

This is enabled by default.

Differential Revision: https://phabricator.services.mozilla.com/D19296

--HG--
extra : moz-landing-system : lando
2019-02-19 06:32:11 +00:00
Emilio Cobos Álvarez d2ed260822 Bug 1517241 - Rename nsIDocument to mozilla::dom::Document. r=smaug
Summary: Really sorry for the size of the patch. It's mostly automatic
s/nsIDocument/Document/ but I had to fix up in a bunch of places manually to
add the right namespacing and such.

Overall it's not a very interesting patch I think.

nsDocument.cpp turns into Document.cpp, nsIDocument.h into Document.h and
nsIDocumentInlines.h into DocumentInlines.h.

I also changed a bunch of nsCOMPtr usage to RefPtr, but not all of it.

While fixing up some of the bits I also removed some unneeded OwnerDoc() null
checks and such, but I didn't do anything riskier than that.
2019-01-03 17:48:33 +01:00