Commit Graph

86 Commits

Author SHA1 Message Date
Emilio Cobos Álvarez
255763ef57 Bug 1773070 - Unify Gecko and Servo EventState/ElementState bits. r=smaug
Add a dom/base/rust crate called just "dom" where we can share these.

Most of the changes are automatic:

  s/mozilla::EventStates/mozilla::dom::ElementState/
  s/EventStates/ElementState/
  s/NS_EVENT_STATE_/ElementState::/
  s/NS_DOCUMENT_STATE_/DocumentState::/

And so on. This requires a new cbindgen version to avoid ugly casts for
large shifts.

Differential Revision: https://phabricator.services.mozilla.com/D148537
2022-06-07 23:09:52 +00:00
Kagami Sascha Rosylight
3d0e3d5413 Bug 1769290 - Part 10: Apply mozilla-js-handle-rooted-typedef against remaining dom directories r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D148283
2022-06-05 20:55:00 +00:00
Kagami Sascha Rosylight
eb5642168c Bug 1768189 - Part 24: Apply modernize-concat-nested-namespaces to dom/performance/PerformanceNavigation.h ... r=andi
Depends on D145757

Differential Revision: https://phabricator.services.mozilla.com/D145758
2022-05-09 20:41:12 +00:00
Tooru Fujisawa
6ea9c3b12c Bug 1752209 - Put cahe type into the cache key in StartupCache/ScriptPreloader. r=nbp
Differential Revision: https://phabricator.services.mozilla.com/D143576
2022-04-13 14:08:07 +00:00
criss
1d40b54278 Backed out 3 changesets (bug 1752209, bug 1752212) for causing build bustages on nsXULPrototypeCache.cpp. CLOSED TREE
Backed out changeset 8f10b666008a (bug 1752209)
Backed out changeset 557c428fb6bc (bug 1752212)
Backed out changeset e38fbd381ed3 (bug 1752212)
2022-04-13 16:09:50 +03:00
Tooru Fujisawa
1e3e102680 Bug 1752209 - Put cahe type into the cache key in StartupCache/ScriptPreloader. r=nbp
Differential Revision: https://phabricator.services.mozilla.com/D143576
2022-04-13 11:41:11 +00:00
Peter Van der Beken
39ce6f48c0 Bug 1749935 - Remove empty nsIContentSink::WillBuildModel/DidBuildModel implementations. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D135845
2022-02-14 13:03:46 +00:00
Peter Van der Beken
8573e064a2 Bug 1749935 - Mark nsIParser::WillResume(Impl) as infallible. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D135836
2022-02-14 13:03:43 +00:00
Tooru Fujisawa
f263a1ae81 Bug 1718481 - Use stencil in nsXULPrototypeCache. r=tcampbell,kmag
Differential Revision: https://phabricator.services.mozilla.com/D121254
2021-09-21 03:18:02 +00:00
Butkovits Atila
8957144a0f Backed out 3 changesets (bug 1718194, bug 1718623, bug 1718481) for causing leaks. CLOSED TREE
Backed out changeset 1cd8bdf1fc92 (bug 1718481)
Backed out changeset aa56fe2c069d (bug 1718194)
Backed out changeset f7cb7313d1c7 (bug 1718623)
2021-09-18 15:47:45 +03:00
Tooru Fujisawa
58155ebcca Bug 1718481 - Use stencil in nsXULPrototypeCache. r=tcampbell,kmag
Differential Revision: https://phabricator.services.mozilla.com/D121254
2021-09-18 11:16:46 +00:00
Gijs Kruitbosch
3355c934ef Bug 1724718 - forget AddTask.js ever existed as bug 1544051 already removed it, r=bgrins
Differential Revision: https://phabricator.services.mozilla.com/D122166
2021-08-10 22:33:06 +00:00
Edgar Chen
1ebbd60592 Bug 1685421 - Part 2: Stop using NS_ERROR_DOM_HIERARCHY_REQUEST_ERR in nsINode; r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D113344
2021-06-02 13:43:39 +00:00
Brendan Dahl
7b2ab557b8 Bug 1651317 - Handle race in script compiling in PrototypeDocumentContentSink. r=smaug
I have still yet to reproduce this. However, it looks like it could happen if
two documents load the same script and they both finish at the same time
and one clears the mCurrentScriptProto of the other.

Differential Revision: https://phabricator.services.mozilla.com/D113602
2021-05-04 00:01:22 +00:00
Andrew McCreight
aa6d815d34 Bug 1704650 - PrototypeDocumentContentSink::mContextSink should be cycle collected. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D111732
2021-04-12 23:07:29 +00:00
Simon Giesecke
7c6ccbe4a8 Bug 1676361 - Move AutoEntryScript to a separate header file to avoid pulling in GeckoProfiler.h everywhere. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D97742
2021-03-05 15:29:49 +00:00
Alexandru Michis
8c28934f09 Backed out changeset c6b72f3c76ba (bug 1676361) for causing bustages in nsSocketTransportService2.cpp
CLOSED TREE
2021-03-04 23:26:04 +02:00
Simon Giesecke
e41d350c04 Bug 1676361 - Move AutoEntryScript to a separate header file to avoid pulling in GeckoProfiler.h everywhere. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D97742
2021-03-04 17:30:48 +00:00
Noemi Erli
11891059f7 Backed out changeset 06452c4c828c (bug 1676361) for causing bustages CLOSED TREE 2021-03-04 19:13:56 +02:00
Simon Giesecke
6c371fcc1c Bug 1676361 - Move AutoEntryScript to a separate header file to avoid pulling in GeckoProfiler.h everywhere. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D97742
2021-03-04 16:14:44 +00:00
smolnar
9f8b74a18d Backed out changeset 9062e17fe15c (bug 1676361) on devs request. CLOSED TREE 2021-03-04 16:51:21 +02:00
Simon Giesecke
e1330cc8f0 Bug 1676361 - Move AutoEntryScript to a separate header file to avoid pulling in GeckoProfiler.h everywhere. r=mccr8
Differential Revision: https://phabricator.services.mozilla.com/D97742
2021-03-04 14:32:15 +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
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
Emilio Cobos Álvarez
fcc0c13711 Bug 1686822 - Execute currently-non-cacheable module scripts in the XUL content sink. r=smaug
See the comments. I'm not sure what the testing story is for the
prototype cache...

Differential Revision: https://phabricator.services.mozilla.com/D101851
2021-01-18 17:38:56 +00:00
Simon Giesecke
e06a2d56fc Bug 1680269 - Fix build when building without MOZ_GECKO_PROFILER. r=gerald
Differential Revision: https://phabricator.services.mozilla.com/D99063
2020-12-09 08:58:06 +00:00
Ricky Stewart
02a7b4ebdf Bug 1654103: Standardize on Black for Python code in mozilla-central.
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-26 18:34:53 +00:00
Bogdan Tara
da1098d4aa Backed out 10 changesets (bug 1654103, bug 1672023, bug 1518999) for PanZoomControllerTest.touchEventForResult gv-junit failures CLOSED TREE
Backed out changeset ff3fb0b4a512 (bug 1672023)
Backed out changeset e7834b600201 (bug 1654103)
Backed out changeset 807893ca8069 (bug 1518999)
Backed out changeset 13e6b92440e9 (bug 1518999)
Backed out changeset 8b2ac5a6c98a (bug 1518999)
Backed out changeset 575748295752 (bug 1518999)
Backed out changeset 65f07ce7b39b (bug 1518999)
Backed out changeset 4bb80556158d (bug 1518999)
Backed out changeset 8ac8461d7bd7 (bug 1518999)
Backed out changeset e8ba13ee17f5 (bug 1518999)
2020-10-24 03:36:18 +03:00
Ricky Stewart
c0cea3b0fa Bug 1654103: Standardize on Black for Python code in mozilla-central. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-23 20:40:42 +00:00
Dorel Luca
1ff59cb7a3 Backed out changeset 7558c8821a07 (bug 1654103) for multiple failures. CLOSED TREE 2020-10-22 03:51:06 +03:00
Ricky Stewart
50762dacab Bug 1654103: Standardize on Black for Python code in mozilla-central. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-21 21:27:27 +00:00
Simon Giesecke
de7bab0f06 Bug 1650145 - Replace all value uses of Empty[C]String by 0-length _ns literals. r=froydnj,geckoview-reviewers,agi
Differential Revision: https://phabricator.services.mozilla.com/D82325
2020-09-23 15:17:15 +00:00
Frederik Braun
a7153982e8 Bug 1366973: Rename security flags to not contain DATA anymore r=geckoview-reviewers,ckerschb,snorp
Differential Revision: https://phabricator.services.mozilla.com/D83490
2020-07-15 11:20:45 +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
Kashav Madan
2b8ca16f35 Bug 1557407 - Replace DispatchTrustedEvent with DispatchEventOnlyToChrome for various chrome-only events, r=smaug
Adds an |aChromeOnlyDispatch| flag to DispatchCustomEvent to decide whether
to call DispatchTrustEvent or DispatchEventOnlyToChrome.

The following chrome-only events are dispatched with DispatchCustomEvent and now
make use of the flag:

- DOMWindowClose
- fullscreen / willenterfullscreen / willexitfullscreen
- occlusionstatechange
- resolutionchange
- XULAlertClose

and the following were previously dispatched with DispatchTrustedEvent and now
use DispatchEventOnlyToChrome:

- MozBeforeInitialXULLayout
- MozMouseScrollFailed / MozMouseScrollTransactionTimeout
- MozPaintWait / MozPaintWaitFinished
- MozPerformDelayedBlur
- all events fired by APZCCallbackHelper::NotifyMozMouseScrollEvent

Differential Revision: https://phabricator.services.mozilla.com/D76723
2020-06-01 17:11:48 +00:00
Sylvestre Ledru
615c83d723 Bug 1519636 - Reformat recent changes to the Google coding style r=andi
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D76451
2020-05-25 07:42:38 +00:00
Emilio Cobos Álvarez
c3b7227771 Bug 1639392 - Merge nsIStyleSheetLinkingElement and nsStyleLinkElement, and call it LinkStyle. r=jwatt
Which is the spec term. nsIStyleSheetLinkingElement is even more
confusing since it may not be an element at all (see: processing
instructions).

Differential Revision: https://phabricator.services.mozilla.com/D76071
2020-05-21 03:07:16 +00:00
Emilio Cobos Álvarez
9bf325345b Bug 1639392 - Move nsIStyleSheetLinkingElement::OverrideBaseURI to its only implementation. r=jwatt
It's a PI thing, so keep it there.

Differential Revision: https://phabricator.services.mozilla.com/D76070
2020-05-21 00:40:31 +00:00
Emilio Cobos Álvarez
7353713339 Bug 1639392 - Remove nsIStyleSheetLinkingElement::InitStyleLinkElement. r=jwatt
Always gets false as an argument, and the value starts false, so it's
just dead code.

Depends on D76067

Differential Revision: https://phabricator.services.mozilla.com/D76068
2020-05-20 17:35:25 +00:00
Razvan Maries
958490b3c1 Backed out 4 changesets (bug 1639392) for build bustages on nsCOMPtr.h. CLOSED TREE
Backed out changeset 379e2c6c0491 (bug 1639392)
Backed out changeset ce2500faad38 (bug 1639392)
Backed out changeset cee5116fbef3 (bug 1639392)
Backed out changeset 7c5823c53db8 (bug 1639392)
2020-05-20 19:36:00 +03:00
Emilio Cobos Álvarez
0b3825c885 Bug 1639392 - Move nsIStyleSheetLinkingElement::OverrideBaseURI to its only implementation. r=jwatt
It's a PI thing, so keep it there.

Depends on D76069

Differential Revision: https://phabricator.services.mozilla.com/D76070
2020-05-20 10:32:14 +00:00
Emilio Cobos Álvarez
4b6f3e905b Bug 1639392 - Remove nsIStyleSheetLinkingElement::InitStyleLinkElement. r=jwatt
Always gets false as an argument, and the value starts false, so it's
just dead code.

Depends on D76067

Differential Revision: https://phabricator.services.mozilla.com/D76068
2020-05-20 10:30:32 +00:00
Zibi Braniecki
9a24b61c50 Bug 1627809 - Rename Document::TriggerInitialTranslation to Document::OnParsingCompleted. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D70974
2020-04-30 17:56:11 +00:00
Zibi Braniecki
30bcee56da Bug 1627809 - Rename *DocumentTranslation to *Translation. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D70971
2020-04-30 17:55:26 +00:00
Peter Van der Beken
86602c0e65 Bug 1628282 - Inline nsDocShell::OnLoadingSite into its only caller. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D70179

--HG--
extra : moz-landing-system : lando
2020-04-08 11:48:56 +00:00
Emilio Cobos Álvarez
ead4d440e7 Bug 1624657 - Use the right document to create elements from the prototype document. r=smaug
This matches closer the behavior of the HTML parser, which doesn't run custom
element constructors, among other things.

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

--HG--
extra : moz-landing-system : lando
2020-04-05 18:36:00 +00:00
Coroiu Cristina
fd8d1a348f Backed out changeset 14eb5adc6cd9 (bug 1624657) for browser-chrome failures at browser/modules/test/browser/browser_UsageTelemetry_searchbar.js 2020-04-05 01:53:18 +03:00
Emilio Cobos Álvarez
c7ca3bd932 Bug 1624657 - Use the right document to create elements from the prototype document. r=smaug
This matches closer the behavior of the HTML parser, which doesn't run custom
element constructors, among other things.

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

--HG--
extra : moz-landing-system : lando
2020-04-04 21:53:38 +00:00
Emilio Cobos Álvarez
c07f3b6b0b Bug 1622235 - Make defer scripts wait for stylesheets. r=hsivonen
Rename ScriptLoader::mDocumentParsingDone to
ScriptLoader::mDeferCheckpointReached, and make it also get unblocked by
stylesheet loading.

Remove a useless null-check for mDocument as we unconditionally dereference it
below when checking mDocument->HaveFiredDOMTitleChange()

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

--HG--
extra : moz-landing-system : lando
2020-03-20 13:33:11 +00:00
Sean Feng
908efe692e Bug 1377999 - Make TextNode to adapt the DOMArena changes r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D62353

--HG--
extra : moz-landing-system : lando
2020-03-17 14:53:54 +00:00