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

4400 Коммитов

Автор SHA1 Сообщение Дата
Yura Zenevich ba825c5746 Bug 1654956 - add AccessibleWalker functionality to show/hide tabbing order overlay. r=jdescottes,devtools-backward-compat-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D94925
2020-11-03 15:33:09 +00:00
Yura Zenevich e669493035 Bug 1654956 - adding TabbingOrderHighlighter that highlights a sequence of nodes within the tabbing order. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D94924
2020-11-03 15:33:01 +00:00
Yura Zenevich 265472b1e2 Bug 1654956 - adding NodeTabbingOrderHighlighter highlighter to highlight nodes that are in the tabbing order for a particular target. r=jdescottes,rcaliman
Differential Revision: https://phabricator.services.mozilla.com/D94923
2020-11-03 15:32:53 +00:00
Razvan Maries 10425eddfc Backed out 7 changesets (bug 1658084, bug 1671983) for perma failures on browser_async_remove_tab.js and browser_e10s_chrome_process.js. CLOSED TREE
Backed out changeset 2e6309c1cdbd (bug 1658084)
Backed out changeset 99aafd9304ef (bug 1671983)
Backed out changeset 80280b85280a (bug 1671983)
Backed out changeset 008db2659002 (bug 1671983)
Backed out changeset 32bd45c7fe3a (bug 1671983)
Backed out changeset 56e227e6580c (bug 1671983)
Backed out changeset a404f809f79d (bug 1671983)
2020-11-04 04:23:47 +02:00
Nika Layzell 5f9c85da95 Bug 1671983 - Part 4: Stop awaiting BrowserTestUtils.loadURI, r=annyG,remote-protocol-reviewers,extension-reviewers,preferences-reviewers,whimboo,zombie
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
2020-11-04 00:55:36 +00:00
Julian Descottes 3ad5aa0547 Bug 1674405 - [devtools] Extract StyleSheet, StyleSheets and MediaRule specs to individual files r=daisuke,devtools-backward-compat-reviewers
Depends on D95328

Differential Revision: https://phabricator.services.mozilla.com/D95329
2020-11-03 15:56:12 +00:00
Julian Descottes bcd5dded83 Bug 1674405 - [devtools] Extract StyleSheet, StyleSheets and MediaRule actors to individual files r=daisuke
Depends on D95299

The actors/stylesheets.js file contained three actors.
This change moves each actor in its own file.

Differential Revision: https://phabricator.services.mozilla.com/D95328
2020-11-02 18:42:53 +00:00
Julian Descottes 3def563fd2 Bug 1674371 - [devtools] Move ELEMENT_STYLE constant to a single file r=rcaliman,devtools-backward-compat-reviewers
Depends on D95299

Differential Revision: https://phabricator.services.mozilla.com/D95307
2020-11-02 18:45:03 +00:00
Julian Descottes 6094cf8dcb Bug 1674362 - [devtools] Extract PageStyle and StyleRule specs to individual files r=rcaliman,devtools-backward-compat-reviewers
Depends on D95297

After moving actors to individual files, we should also do the same with specs.
Both actors are using shared types, which are moved to a shared types file.

Differential Revision: https://phabricator.services.mozilla.com/D95298
2020-11-02 18:35:28 +00:00
Julian Descottes 51323f232a Bug 1674362 - [devtools] Extract PageStyle and StyleRule actors to individual files r=rcaliman
The actors/styles.js file contained two actors.
This change moves each actor in its own file.
A shared actors/utils/style-utils file is also created to host shared helpers.

Differential Revision: https://phabricator.services.mozilla.com/D95297
2020-11-02 17:14:55 +00:00
Belén Albeza 65ade5bf66 Bug 1669509 - [devtools] Hide internal indexedDB's when we are not in the browser toolbox r=ochameau
In https://phabricator.services.mozilla.com/D91122#C3084925OL296 we transferred the filtering of indexedDB dbs to a transformer, but it was not being applied since the `hosts` getter was still used by the client. Since we discussed this filtering should be done in the server, this patch moves the filtering to the storage actor instead.

Differential Revision: https://phabricator.services.mozilla.com/D95020
2020-11-02 13:28:56 +00:00
Belén Albeza 6ce63ec0cd Bug 1666528 - [devtools] Add session storage resource + test r=ochameau
Differential Revision: https://phabricator.services.mozilla.com/D94728
2020-10-30 16:12:58 +00:00
Csoregi Natalia c9031b88f2 Backed out changeset 5a4c2dc63d04 (bug 1669509) for causing leaks. CLOSED TREE 2020-10-30 18:50:11 +02:00
Belén Albeza a2eed98a2c Bug 1669509 - [devtools] Hide internal indexedDB's when we are not in the browser toolbox r=ochameau
In https://phabricator.services.mozilla.com/D91122#C3084925OL296 we transferred the filtering of indexedDB dbs to a transformer, but it was not being applied since the `hosts` getter was still used by the client. Since we discussed this filtering should be done in the server, this patch moves the filtering to the storage actor instead.

Differential Revision: https://phabricator.services.mozilla.com/D95020
2020-10-30 13:33:47 +00:00
Alexandre Poirot 1cca051c93 Bug 1673328 - [devtools] Stop using requestTypes in ThreadActor. r=nchevobbe
This was hacking the internals of RDP/protocol.js in order to provide
different names to the actor prototype.
I had to rename existing `skipBreakpoints` getter in order to avoid
name collision with the RDP method of the same name.
I also had to tweak a few method arguments as they weren't following protocol.js spec.
They were called without protocol.js automatic marshalling of values.
Finally, hack something in protocol.js in order to avoid duplicated response for ThreadActor.attach.

Differential Revision: https://phabricator.services.mozilla.com/D94958
2020-10-29 18:58:33 +00:00
Alexandre Poirot ce474dc715 Bug 1673328 - [devtools] Rename TabSources to SourcesManager. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D95042
2020-10-29 19:00:26 +00:00
Alexandre Poirot 90a993e0b7 Bug 1673328 - [devtools] Drop ThreadActor.exit in favor of destroy. r=nchevobbe
We no longer need to manuall call threadActor.exit from Target Actors
as the ThreadActor is managed by the Target Actors, so that managed children
will be destroyed when the target actor is destroyed.

Differential Revision: https://phabricator.services.mozilla.com/D94957
2020-10-29 18:59:35 +00:00
Alexandre Poirot fdb8f8c40d Bug 1673328 - [devtools] Drop unused ThreadActor.detach method. r=nchevobbe,devtools-backward-compat-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D94956
2020-10-29 19:00:39 +00:00
Alexandre Poirot e5dd1d7904 Bug 1671906 - [devtools] Introduce a target actor mixin in order to share common code between all targets. r=jdescottes
Similarly to the frontend, I'm introducing a mixin in order to share code between at target actors.
We might be able to share more, like sources. But at least we share new addition related to watcher and resources.
This would probably have been easier if Actor were using ES Classes.

Differential Revision: https://phabricator.services.mozilla.com/D94948
2020-10-29 16:46:20 +00:00
Hubert Boma Manilla f2eff26a41 Bug 1667370 - [devtools] Implement network request blocking in fission r=ochameau,devtools-backward-compat-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D94449
2020-10-28 22:32:14 +00:00
Daisuke Akatsuka 473676fda0 Bug 1664941: Connect style actor and stylesheet watcher. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D90651
2020-10-29 06:26:20 +00:00
Cosmin Sabou 7a1d8770ac Backed out changeset 3b72cf9476d8 (bug 1667370) for xpc failures on test_protocol_index.js. CLOSED TREE 2020-10-28 23:35:36 +02:00
Hubert Boma Manilla 3d18cd113c Bug 1667370 - [devtools] Implement network request blocking in fission r=ochameau,devtools-backward-compat-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D94449
2020-10-28 20:46:13 +00:00
Julian Descottes b5906333d9 Bug 1654998 - [devtools] Remove backward compatibility code from storage-ui::_readSupportsTraits r=ladybenko
Traits support was added to the storage actor in FF80.
Firefox release is now FF81 so we can cleanup the related backward compatibility code.

Differential Revision: https://phabricator.services.mozilla.com/D93081
2020-10-28 20:19:06 +00:00
Nicolas Chevobbe f24966129e Bug 1673550 - [devtools] Destroy the thread actor when the worker target actor is destroyed. r=ochameau.
We have to manually call `ThreadActor#exit` as calling `destroy` won't completely
destroy it, since it does not call `Actor#destroy`, whereas `ThreadActor#exit` does.

Differential Revision: https://phabricator.services.mozilla.com/D94835
2020-10-27 15:10:46 +00:00
Neil Deakin 46d6cc2f05 Bug 1672390, remove message manager use from browser_connectToFrame.js, r=ochameau
Differential Revision: https://phabricator.services.mozilla.com/D94667
2020-10-27 00:26:35 +00:00
Neil Deakin 42167e0a0f Bug 1672390, remove message manager and frame scripts from devtools/client/performance, r=ochameau
Differential Revision: https://phabricator.services.mozilla.com/D94388
2020-10-27 00:26:14 +00:00
Fabien CASTERS 054244e95b Bug 1672433 - Remove backward compatibility method getDescription from devtools/client/fronts/device.js r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D94731
2020-10-26 20:20:57 +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
Nicolas Chevobbe edca74234a Bug 1633712 - [devtools] Create WorkerTargets as soon as possible. r=ochameau,devtools-backward-compat-reviewers.
This patch adds support for dedicated worker targets in the Watcher actor.
Shared and Service workers are not handled yet.

In a similar manner to what we already have for frame targets, we add a worker-helper
file that will communicate with a JsWindowActor pair spawned on each document,
that will  manage workers (DevToolsWorkerParent/DevToolsWorkerChild).

For a given document, the DevToolsWorkerChild will enumerate the existing workers
related to it, as well as add an event listener to be notified when workers are
being registered and unregistered, and communicate that back to the DevToolsWorkerParent
on the main thread, so worker targets creation and destruction are notified by
the Watcher actor (via target-available-form and target-destroyed-form events).

When a worker is created, the DevToolsWorkerChild for the document the worker
was spawned from will create a WorkerTargetActor, that will live in the worker
thread (using worker-connector.js), passing it resources the Watcher is currently
listening for. It will also handle communication between the main thread and the
worker thread, when the watcher listen to new resources (or stop watching resources).

A WorkerTargetFront is created so the client can be notified about available
resources (via the resource-available-form event, emitted from the worker target).

Tests are added in the next patches of this queue.

Differential Revision: https://phabricator.services.mozilla.com/D85399
2020-10-26 12:53:43 +00:00
Nicolas Chevobbe 268a9bef36 Bug 1633712 - [devtools] Move shouldNotifyWindowGlobal and getAllRemoteBrowsingContexts to a util file. r=ochameau.
These functions will be used by the worker-helper.js module as well.

Differential Revision: https://phabricator.services.mozilla.com/D92751
2020-10-26 12:52:26 +00:00
Alexandre Poirot ecca7cad66 Bug 1672778 - [devtools] Avoid trying to send new-source event if the thread actor has been destroyed. r=nchevobbe
This may prevent logging a few exception or error messages.
But thanks to the other patch of this bug, we should try to stop listening
for sources as soon as the thread actor is destroyed.

Differential Revision: https://phabricator.services.mozilla.com/D94484
2020-10-23 10:24:57 +00:00
Alexandre Poirot 2839b0697a Bug 1672778 - [devtools] Destroy the thread actor when the content process actor is destroyed. r=nchevobbe
We have to manually call `exit` as calling `destroy` won't completely destroy it.
ThreadActor.destroy do not call protocoljs.Actor.destroy, ThreadActor.exit does it.

Differential Revision: https://phabricator.services.mozilla.com/D94483
2020-10-26 11:00:05 +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
Belén Albeza e6d07a37fa Bug 1666519 - Part 1: [devtools] Add localStorage resource r=ochameau
Tests are added in the next revision of the stack: D93808

Differential Revision: https://phabricator.services.mozilla.com/D92634
2020-10-23 11:58:45 +00:00
Ben Delevingne 4c645f7aaa Bug 1672364 - remove defer from devtools/server. r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D94296
2020-10-23 10:56:00 +00:00
Razvan Caliman 7feae1e668 Bug 1623667 - [devtools] Update CustomHighlighterActor comments and docs r=ochameau
Depends on D92220

Rephrasing of code comments and cleanup of documentation to reflect that `CustomHighlighterActor` is now the only actor which deals with highlighting stuff after removing `HighlighterActor` in D92220. No functionality is changed in this patch.

Differential Revision: https://phabricator.services.mozilla.com/D92221
2020-10-20 14:43:20 +00:00
Razvan Caliman 8dacfff4f6 Bug 1623667 - [devtools] Remove HighlighterActor r=ochameau,devtools-backward-compat-reviewers
This patch completely removes the `HighlighterActor` and its accessors.

The rest of the patches in this commit series update the consumers and tests to use the new highlighter manager added to `HighlightersOverlay` in D81526. [Bug 1646028](https://bugzilla.mozilla.org/show_bug.cgi?id=1646028) updated all consumers within the **Inspector** panel to use this approach. Now, we're updating the rest of the consumers outside the Inspector.

### Why remove HighlighterActor?

The changes introduced in D81526 for [Bug 1646028](https://bugzilla.mozilla.org/show_bug.cgi?id=1646028) make it possible to  highlight nodes using the `CustomHighligtherActor` with the **Box Model Highlighter** implementation.

The `HighlighterActor` was itself a wrapper around **Box Model Highlighter** and Simple Outline Highlighter, and exposed node picking functionality. Simple Outline Highlighter was removed with [Bug 1650094](https://bugzilla.mozilla.org/show_bug.cgi?id=1650094). The node picking functionality was decoupled from `HighlighterActor`in [Bug 1607756](https://bugzilla.mozilla.org/show_bug.cgi?id=1607756).

After those changes, `HighlighterActor` is no longer special. It can be removed in favor of a single generic actor, `CustomHighligtherActor`, with the Box Model Highlighter implementation.

Differential Revision: https://phabricator.services.mozilla.com/D92220
2020-10-20 14:43:23 +00:00
Alexandre Poirot 8458fea935 Bug 1672660 - [devtools] Unregister docshell listeners only if we had time to register them. r=nchevobbe
It looks like we are destroying the target actor immediately, without having time
to call _watchDocshells. And given that removeObserver throws if there is no matching listener
already registered, it prevent detaching the target correctly, and, introduces a leak.

Differential Revision: https://phabricator.services.mozilla.com/D94452
2020-10-22 20:13:28 +00:00
Alexandre Poirot fe4803309b Bug 1620248 - [devtools] Rename content-process.jsm init method to initContentProcessTarget. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D94373
2020-10-22 10:02:47 +00:00
Alexandre Poirot 8cfdbef9f5 Bug 1620248 - [devtools] Create ContentProcessTarget from the server side via the Watcher Actor. r=nchevobbe,jdescottes
Before, targets were created on-demand, from the frontend, by calling ProcessDescriptor.getTarget
when the root actor informed the frontend of a creation of a content process via processListChanged event
and the notification of a new ProcessDescriptor.
This previous behavior was making so that the target actor was created very late and did not allow
recording for resources (console messages for ex), nor setting breakpoints very early during the process startup.

With this new implementation, the watcher actor allows knowing if the frontend cares about content process target or not.
We should only create these targets if the browser toolbox is opened, and typically not if we are only debugging a tab via a regular web toolbox.
We do that via WatcherActor.watchTarget and sharedData object.
content-process-script.js is loaded in all processes. Process script are loaded quite early during process startup.
Soonish after `sharedData` is passed to the content process.
So that it is hopefully executed before most privileged javascript runs.
Javascript code where we possibly want to debug/observe/set a breakpoint on.
This setup allows us to create the Content Process Target actor much earlier than the previous setup.
When created, the target actor immediately start listening for resources (console message and others) via its `addWatcherDataEntry` method.
In a near future, breakpoints will also be set via this method.

We should also followup to use something else than Process Script and sharedData
in order to create the target earlier, before any JS runs.

Differential Revision: https://phabricator.services.mozilla.com/D65529
2020-10-22 10:02:42 +00:00
Alexandre Poirot 23e54f0836 Bug 1620248 - [devtools] Make hooks.onClosed optional for all Transport classes. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D93193
2020-10-22 10:02:34 +00:00
Alexandre Poirot e1aa84044b Bug 1620248 - [devtools] Ensure destroying ContentProcess target when the target is destroyed before process shutdown. r=nchevobbe,jdescottes
For now, we were emitting the "tabDetached" event on message-manager-close (=process shutdown),
or when the DevToolsServerConnection closes (=client closes the connection).
But not when the target is being destroyed by the frontend when calling ResourceWatcher.unwatchTargets,
which is calling process-helper's destroyTargets.
This was introducing test failure (browser_target_list_watchTargets.js) with never resolving RDP requests.

Differential Revision: https://phabricator.services.mozilla.com/D91559
2020-10-22 10:02:31 +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
Bogdan Tara 3f38cbb0f8 Backed out 2 changesets (bug 1666519) for devtools leaks and failures CLOSED TREE
Backed out changeset 94c066ab05dc (bug 1666519)
Backed out changeset 990b312b5abe (bug 1666519)
2020-10-21 18:42:25 +03:00
Emilio Cobos Álvarez 9944e5344c Bug 1634776 - Fix some cascade level checks in devtools. r=rcaliman
The regression was caused because it incorrectly started treating user
stylesheets as "system" sheets, which can't be modified.

Fix the regression by properly using SharedCssLogic.isAgentStylesheet
instead.

Also fix the check for whether chrome rules apply to handle user
stylesheets and inline style attributes in chrome documents correctly,
see the comment.

Differential Revision: https://phabricator.services.mozilla.com/D93088
2020-10-21 14:56:46 +00:00
Belén Albeza 223b34efcf Bug 1666519 - Part 1: [devtools] Add localStorage resource r=ochameau
Tests are added in the next revision of the stack: D93808

Differential Revision: https://phabricator.services.mozilla.com/D92634
2020-10-21 14:05:14 +00:00
Julian Descottes f78ea8ee85 Bug 1671676 - [devtools] Update browser_setupInParentChild.js to only test setupInParent r=ochameau
Depends on D93821

Differential Revision: https://phabricator.services.mozilla.com/D93822
2020-10-20 20:48:54 +00:00
Julian Descottes 138356ac36 Bug 1671676 - [devtools] Remove setupInChild from DevTools codebase r=ochameau
Depends on D93820

This is no longer used, except in one test which will be cleaned up in the next changeset.

Differential Revision: https://phabricator.services.mozilla.com/D93821
2020-10-20 20:48:35 +00:00
Julian Descottes 134032de33 Bug 1671609 - [devtools] Simplify message manager handling in storage actor r=ochameau,ladybenko
Depends on D93817

There should no longer be new message managers during the lifecycle of the actor.
We can simplify the storage actor thanks to this.

Differential Revision: https://phabricator.services.mozilla.com/D93819
2020-10-20 17:02:36 +00:00
Julian Descottes 23b2aef1c7 Bug 1671609 - [devtools] Remove browserSwap support from devtools r=ochameau
This method was only useful for the old RDM implementation and can now be removed.

Differential Revision: https://phabricator.services.mozilla.com/D93817
2020-10-20 17:02:34 +00:00
Razvan Maries 3954e7eb5a Backed out 5 changesets (bug 1671676, bug 1671609) for Lint failure on frame.js. CLOSED TREE
Backed out changeset aba7c7caae10 (bug 1671676)
Backed out changeset 68449199cb9a (bug 1671676)
Backed out changeset 107e0c2f141a (bug 1671609)
Backed out changeset 02bc34c28501 (bug 1671609)
Backed out changeset 5efd9f6968ed (bug 1671609)
2020-10-20 19:59:11 +03:00
Julian Descottes 305bfc6182 Bug 1671676 - [devtools] Update browser_setupInParentChild.js to only test setupInParent r=ochameau
Depends on D93821

Differential Revision: https://phabricator.services.mozilla.com/D93822
2020-10-19 09:59:11 +00:00
Julian Descottes aef14fc3b4 Bug 1671676 - [devtools] Remove setupInChild from DevTools codebase r=ochameau
Depends on D93820

This is no longer used, except in one test which will be cleaned up in the next changeset.

Differential Revision: https://phabricator.services.mozilla.com/D93821
2020-10-19 19:34:25 +00:00
Julian Descottes 157cd2cea2 Bug 1671609 - [devtools] Simplify message manager handling in storage actor r=ochameau,ladybenko
Depends on D93817

There should no longer be new message managers during the lifecycle of the actor.
We can simplify the storage actor thanks to this.

Differential Revision: https://phabricator.services.mozilla.com/D93819
2020-10-20 16:23:08 +00:00
Julian Descottes 66b1914d6f Bug 1671609 - [devtools] Remove browserSwap support from devtools r=ochameau
This method was only useful for the old RDM implementation and can now be removed.

Differential Revision: https://phabricator.services.mozilla.com/D93817
2020-10-19 09:32:56 +00:00
Csoregi Natalia f9e58cacd1 Backed out 9 changesets (bug 1623667) for failures on devtools/client/*. CLOSED TREE
Backed out changeset 54ca4d13f54f (bug 1623667)
Backed out changeset ce62de8733f1 (bug 1623667)
Backed out changeset 4877c0c5ba2c (bug 1623667)
Backed out changeset d32decff7ea8 (bug 1623667)
Backed out changeset 53a2c44f955b (bug 1623667)
Backed out changeset 0addf3282b72 (bug 1623667)
Backed out changeset feeb0f0b3bb3 (bug 1623667)
Backed out changeset f90ccc4f5210 (bug 1623667)
Backed out changeset e18376ee942f (bug 1623667)
2020-10-20 17:39:28 +03:00
Razvan Caliman 1d2ad58af3 Bug 1623667 - [devtools] Update CustomHighlighterActor comments and docs r=ochameau
Depends on D92220

Rephrasing of code comments and cleanup of documentation to reflect that `CustomHighlighterActor` is now the only actor which deals with highlighting stuff after removing `HighlighterActor` in D92220. No functionality is changed in this patch.

Differential Revision: https://phabricator.services.mozilla.com/D92221
2020-10-14 14:19:39 +00:00
Razvan Caliman e7d88cfad5 Bug 1623667 - [devtools] Remove HighlighterActor r=ochameau,devtools-backward-compat-reviewers
This patch completely removes the `HighlighterActor` and its accessors.

The rest of the patches in this commit series update the consumers and tests to use the new highlighter manager added to `HighlightersOverlay` in D81526. [Bug 1646028](https://bugzilla.mozilla.org/show_bug.cgi?id=1646028) updated all consumers within the **Inspector** panel to use this approach. Now, we're updating the rest of the consumers outside the Inspector.

### Why remove HighlighterActor?

The changes introduced in D81526 for [Bug 1646028](https://bugzilla.mozilla.org/show_bug.cgi?id=1646028) make it possible to  highlight nodes using the `CustomHighligtherActor` with the **Box Model Highlighter** implementation.

The `HighlighterActor` was itself a wrapper around **Box Model Highlighter** and Simple Outline Highlighter, and exposed node picking functionality. Simple Outline Highlighter was removed with [Bug 1650094](https://bugzilla.mozilla.org/show_bug.cgi?id=1650094). The node picking functionality was decoupled from `HighlighterActor`in [Bug 1607756](https://bugzilla.mozilla.org/show_bug.cgi?id=1607756).

After those changes, `HighlighterActor` is no longer special. It can be removed in favor of a single generic actor, `CustomHighligtherActor`, with the Box Model Highlighter implementation.

Differential Revision: https://phabricator.services.mozilla.com/D92220
2020-10-13 15:40:13 +00:00
Hubert Boma Manilla 3d1f26e2cd Bug 1663523 - [devtools] Add the network event stacktrace watcher r=ochameau,devtools-backward-compat-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D86809
2020-10-19 01:19:39 +00:00
Bogdan Tara 61728de827 Backed out changeset de71a00c6f68 (bug 1663523) for devtools/shared/ failures CLOSED TREE 2020-10-18 20:53:17 +03:00
Hubert Boma Manilla 403ec0015b Bug 1663523 - [devtools] Add the network event stacktrace watcher r=ochameau,devtools-backward-compat-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D86809
2020-10-18 17:11:36 +00:00
Hubert Boma Manilla 30aacc98e1 Bug 1670627 - [devtools] Pass the updateType to the data provider on the resource update event r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D93700
2020-10-16 09:42:48 +00:00
Alexandre Poirot be7dd39054 Bug 1671419 - [devtools] Avoid updating resource types if the list is empty. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D93657
2020-10-15 18:55:59 +00:00
Csoregi Natalia e0eb861a18 Backed out 4 changesets (bug 1633712) for leaks. CLOSED TREE
Backed out changeset 03553b300b86 (bug 1633712)
Backed out changeset 19c8ea0b43df (bug 1633712)
Backed out changeset 6eaa4d12b58c (bug 1633712)
Backed out changeset 10f97f47c883 (bug 1633712)
2020-10-15 09:36:36 +03:00
Nicolas Chevobbe 1e17daf388 Bug 1633712 - [devtools] Create WorkerTargets as soon as possible. r=ochameau,devtools-backward-compat-reviewers.
This patch adds support for dedicated worker targets in the Watcher actor.
Shared and Service workers are not handled yet.

In a similar manner to what we already have for frame targets, we add a worker-helper
file that will communicate with a JsWindowActor pair spawned on each document,
that will  manage workers (DevToolsWorkerParent/DevToolsWorkerChild).

For a given document, the DevToolsWorkerChild will enumerate the existing workers
related to it, as well as add an event listener to be notified when workers are
being registered and unregistered, and communicate that back to the DevToolsWorkerParent
on the main thread, so worker targets creation and destruction are notified by
the Watcher actor (via target-available-form and target-destroyed-form events).

When a worker is created, the DevToolsWorkerChild for the document the worker
was spawned from will create a WorkerTargetActor, that will live in the worker
thread (using worker-connector.js), passing it resources the Watcher is currently
listening for. It will also handle communication between the main thread and the
worker thread, when the watcher listen to new resources (or stop watching resources).

A WorkerTargetFront is created so the client can be notified about available
resources (via the resource-available-form event, emitted from the worker target).

Tests are added in the next patches of this queue.

Differential Revision: https://phabricator.services.mozilla.com/D85399
2020-10-15 05:17:52 +00:00
Nicolas Chevobbe 54da2bd313 Bug 1633712 - [devtools] Move shouldNotifyWindowGlobal and getAllRemoteBrowsingContexts to a util file. r=ochameau.
These functions will be used by the worker-helper.js module as well.

Differential Revision: https://phabricator.services.mozilla.com/D92751
2020-10-15 05:11:58 +00:00
JulianWels b88cf407ac Bug 1608074 - Set channel ReferrerInfo in privileged code instead of referrer header r=nchevobbe,mixedpuppy,valentin
Differential Revision: https://phabricator.services.mozilla.com/D59856
2020-10-13 12:27:26 +00:00
Mihai Alexandru Michis 55dd1dbe43 Backed out changeset b3fb1b5bbe34 (bug 1608074) for causing bustages in XMLHttpRequestMainThread.cpp
CLOSED TREE
2020-10-13 14:55:06 +03:00
JulianWels 2ae8134434 Bug 1608074 - Set channel ReferrerInfo in privileged code instead of referrer header r=nchevobbe,mixedpuppy,valentin
Differential Revision: https://phabricator.services.mozilla.com/D59856
2020-10-13 10:39:11 +00:00
Julian Descottes 4d7f2e708f Bug 1669681 - [devtools] Ignore detach errors when purging Front requests r=ochameau
Depends on D92756

Detach errors can happen when a target is being destroyed.
Historically, those errors were swallowed in the TargetFront mixin.
However this logic became outdated when we started purging requests during Front::destroy.

This results in non-actionable error messages logged frequently while using DevTools.
This changeset updates the logic in target-mixin.js in order to swallow errors due to purged requests.

Differential Revision: https://phabricator.services.mozilla.com/D92757
2020-10-12 08:12:53 +00:00
Julian Descottes d4c1319148 Bug 1669681 - [devtools] Stop processing packet responses in destroyed Fronts r=ochameau
Depends on D93030

All Front requests are purged before the Front is destroyed.
In theory there is no reason to process packets after the Front has been destroyed.
It will only create cryptic error messages.

Differential Revision: https://phabricator.services.mozilla.com/D92756
2020-10-12 08:13:06 +00:00
Alexandre Poirot 342c1ad0be Bug 1669545 - [devtools] Print internal error codes instead of only "Blocked" when there is not explicit blocking reason. r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D92657
2020-10-09 13:45:55 +00:00
Emilio Cobos Álvarez 4d89ea6d7c Bug 1654866 - Make style inspector account for UA/chrome sheets and quirks properly. r=rcaliman
Differential Revision: https://phabricator.services.mozilla.com/D92633
2020-10-09 11:56:18 +00:00
Sylvestre Ledru cad53f4804 Bug 1588458 - Replace dxr links by searchfox in the code/test r=kats,sparky
Differential Revision: https://phabricator.services.mozilla.com/D92792
2020-10-08 14:02:40 +00:00
Alexandre Poirot af7666a292 Bug 1669527 - [devtools] Ensure destroying the NetworkMonitorActor spawn in the parent process. r=Honza,jdescottes
The WebConsoleActor tries to destroy it via a debug:destroy-network-monitor.
But as it is done during the destruction of the target actor, typically when there is a
top level target switching, this message doesn't reach the parent process.
So, ensure destroying this actor from the parent process side, when we see that the
frame target is being destroyed.

Differential Revision: https://phabricator.services.mozilla.com/D92654
2020-10-07 13:39:48 +00:00
Alexandre Poirot e11f76a190 Bug 1669473 - [devtools] Fix a typo around event timings. r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D92605
2020-10-07 16:00:50 +00:00
Alexandre Poirot e69ee12648 Bug 1669473 - [devtools] add built-in logging for platform events in NetworkObserver. r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D92604
2020-10-07 16:00:47 +00:00
Nicolas Chevobbe 37873fd6f8 Bug 1669655 - [devtools] Cleanup worker-connector.js and startup/worker.js. r=ochameau.
- Rename `id` to a more explicit `forwardingPrefix` property
- Add comments to why we need to handle a list of connections
- Remove the `rpcs` property from the connections object
- Turn `rpcDeferred` from an array to an object, as it's used like one.

Differential Revision: https://phabricator.services.mozilla.com/D92752
2020-10-08 05:54:18 +00:00
Razvan Maries e523193665 Backed out 2 changesets (bug 1669473) for perma failures on browser_net_block-csp.js. CLOSED TREE
Backed out changeset d798c548257e (bug 1669473)
Backed out changeset d25a3deb4961 (bug 1669473)
2020-10-07 17:46:31 +03:00
Alexandre Poirot 434bebe5da Bug 1669473 - [devtools] Fix a typo around event timings. r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D92605
2020-10-07 08:24:51 +00:00
Alexandre Poirot 73a6605181 Bug 1669473 - [devtools] add built-in logging for platform events in NetworkObserver. r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D92604
2020-10-07 11:35:03 +00:00
Alexandre Poirot 2c3d8677f9 Bug 1667839 - Pass watchedData to already existing targets. r=nchevobbe
The previous code was all wrong and we weren't correctly listening to resource
for already existing additional targets. Top level target was still working fine
thanks to WatcherActor.watchResources calling watchTargetResource directly.

Differential Revision: https://phabricator.services.mozilla.com/D91969
2020-10-05 20:52:23 +00:00
Gabriel Luong 7afa635edb Bug 1662059 - [devtools] Only read devtools.overflow.debugging.enabled from the client. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D92363
2020-10-06 02:50:38 +00:00
Gabriel Luong 18a75c17f7 Bug 1660973 - [devtools] Return a disconnectedNodeArray for getOverflowCausingElements. r=jdescottes,devtools-backward-compat-reviewers
The problem with `getOverflowCausingElement`s seems to be that it returned an array
of nodes that weren't properly attached to their parents.

To mitigate this, we call `attachElements` on the entire list of nodes and
return a `disconnectedNodeArray` which ensures that the returned nodes
are properly attached and therefore has all their parent node information
when calling `showNode`.

Differential Revision: https://phabricator.services.mozilla.com/D92360
2020-10-05 15:58:21 +00:00
Gijs Kruitbosch 1aa2c4d5db Bug 1668274 - update eslint, eslint-plugin-no-unsanitized and mocha to allow use of logical assignment operators, r=Standard8
Differential Revision: https://phabricator.services.mozilla.com/D91933
2020-10-02 18:00:40 +00:00
Nicolas Chevobbe 6e140506a1 Bug 1662734 - [devtools] Create an actual WorkerTargetActor and use it in startup/worker.js . r=ochameau,jdescottes,devtools-backward-compat-reviewers.
This patch adds a simple WorkerTargetActor, which is similar to the mock target
actor we had in startup/worker.js.

Its spec file is empty at the moment, and it does not have an associated front,
but that might change with Bug 1633712 where we will at least have events for
resources available/destroyed.

Differential Revision: https://phabricator.services.mozilla.com/D91128
2020-09-29 14:47:34 +00:00
Nicolas Chevobbe 056b9542f2 Bug 1573779 - [devtools] Rename WorkerTargetActorList to WorkerDescriptorActorList. r=jdescottes.
This class is creating (and handling) WorkerDescriptorActor now, so we rename
it to make it explicit.

Differential Revision: https://phabricator.services.mozilla.com/D91557
2020-09-29 14:31:10 +00:00
Nicolas Chevobbe f315ff58cd Bug 1573779 - [devtools] Rename WorkerTarget to WorkerDescriptor. r=ochameau,jdescottes,devtools-backward-compat-reviewers.
This renames the current WorkerTargetActor which is actually a descriptor.
We also rename the existing `workerTargetFront` occurences to `workerDescriptorFront`
to avoid confusion when we do introduce the real worker fronts and actors.

Differential Revision: https://phabricator.services.mozilla.com/D91100
2020-09-29 14:30:24 +00:00
Dorel Luca f826d52619 Backed out 3 changesets (bug 1573779, bug 1662734) for Geckoview failures. CLOSED TREE
Backed out changeset 0adff4f08b28 (bug 1662734)
Backed out changeset c6bb84f2a032 (bug 1573779)
Backed out changeset 0c605800aa6b (bug 1573779)
2020-09-29 12:59:39 +03:00
Nicolas Chevobbe 68ba8f3d46 Bug 1662734 - [devtools] Create an actual WorkerTargetActor and use it in startup/worker.js . r=ochameau,jdescottes,devtools-backward-compat-reviewers.
This patch adds a simple WorkerTargetActor, which is similar to the mock target
actor we had in startup/worker.js.

Its spec file is empty at the moment, and it does not have an associated front,
but that might change with Bug 1633712 where we will at least have events for
resources available/destroyed.

Differential Revision: https://phabricator.services.mozilla.com/D91128
2020-09-28 12:29:11 +00:00
Nicolas Chevobbe bda0dabd83 Bug 1573779 - [devtools] Rename WorkerTargetActorList to WorkerDescriptorActorList. r=jdescottes.
This class is creating (and handling) WorkerDescriptorActor now, so we rename
it to make it explicit.

Differential Revision: https://phabricator.services.mozilla.com/D91557
2020-09-29 01:54:32 +00:00
Nicolas Chevobbe 4914f8c614 Bug 1573779 - [devtools] Rename WorkerTarget to WorkerDescriptor. r=ochameau,jdescottes,devtools-backward-compat-reviewers.
This renames the current WorkerTargetActor which is actually a descriptor.
We also rename the existing `workerTargetFront` occurences to `workerDescriptorFront`
to avoid confusion when we do introduce the real worker fronts and actors.

Differential Revision: https://phabricator.services.mozilla.com/D91100
2020-09-28 12:27:22 +00:00
Frederic Wang 0eebca3c33 Bug 1667118 - Rename -moz-math-script-level to math-depth. r=emilio
This renames the internal -moz-math-script-level property in order to
prepare for full math-depth support. Currently, the property is guarded
under a disabled-by-default flag, so there should be no observable
behavior change.

Differential Revision: https://phabricator.services.mozilla.com/D91285
2020-09-26 03:04:56 +00:00
Narcis Beleuzu 679469fad8 Backed out changeset 239f29a99c4f (bug 1667118) for bc failure on browser_parsable_css.js . CLOSED TREE 2020-09-25 23:39:15 +03:00
Frederic Wang 5461921d85 Bug 1667118 - Rename -moz-math-script-level to math-depth. r=emilio
This renames the internal -moz-math-script-level property in order to
prepare for full math-depth support. Currently, the property is guarded
under a disabled-by-default flag, so there should be no observable
behavior change.

Differential Revision: https://phabricator.services.mozilla.com/D91285
2020-09-25 18:37:39 +00:00
Mihai Alexandru Michis cc04d2696e Backed out changeset b08319695e21 (bug 1667118) for causing xpcshell failures in test_css-properties-db.js
CLOSED TREE
2020-09-25 16:40:33 +03:00
Frederic Wang eb4b491896 Bug 1667118 - Rename -moz-math-script-level to math-depth. r=emilio
This renames the internal -moz-math-script-level property in order to
prepare for full math-depth support. Currently, the property is guarded
under a disabled-by-default flag, so there should be no observable
behavior change.

Differential Revision: https://phabricator.services.mozilla.com/D91285
2020-09-25 12:04:53 +00:00
Razvan Maries ed260c95a0 Backed out changeset 08538390d573 (bug 1667118) for perma failures on test_css-properties-db.js. CLOSED TREE 2020-09-25 00:12:10 +03:00
Frederic Wang c828ccef71 Bug 1667118 - Rename -moz-math-script-level to math-depth. r=emilio
This renames the internal -moz-math-script-level property in order to
prepare for full math-depth support. Currently, the property is guarded
under a disabled-by-default flag, so there should be no observable
behavior change.

Differential Revision: https://phabricator.services.mozilla.com/D91285
2020-09-24 18:44:41 +00:00
Frederic Wang aec8cecc03 Bug 1665975 - Implement the math-style property. r=emilio
This patch renames the internal -moz-math-display to math-style and
exposes it under the layout.css.math-style.enabled preference. The
initial value becomes "normal" but that does not affect the default
MathML behavior since the UA style sheet sets the math-style property
explicitly on <math> tags. WPT tests are updated to use the syntax
approved by the CSSWG.

Intent to prototype: https://groups.google.com/forum/#!msg/mozilla.dev.platform/1hQQ7ISudGo/_yLEckEeBQAJ

Differential Revision: https://phabricator.services.mozilla.com/D90731
2020-09-23 13:04:48 +00:00
Narcis Beleuzu 85b4b24cfc Backed out changeset 9480237e1e6f (bug 1665975) for xpcshell failure on test_css-properties-db.js. CLOSED TREE 2020-09-23 13:06:21 +03:00
Frederic Wang ff5e02320a Bug 1665975 - Implement the math-style property. r=emilio
This patch renames the internal -moz-math-display to math-style and
exposes it under the layout.css.math-style.enabled preference. The
initial value becomes "normal" but that does not affect the default
MathML behavior since the UA style sheet sets the math-style property
explicitly on <math> tags. WPT tests are updated to use the syntax
approved by the CSSWG.

Intent to prototype: https://groups.google.com/forum/#!msg/mozilla.dev.platform/1hQQ7ISudGo/_yLEckEeBQAJ

Differential Revision: https://phabricator.services.mozilla.com/D90731
2020-09-23 08:14:38 +00:00
Bogdan Tara 2991b8c066 Backed out changeset 0da5103ba772 (bug 1665975) for mozglue_static::panic_hook mass crashes CLOSED TREE 2020-09-21 10:07:03 +03:00
Frederic Wang 1ac695dbdc Bug 1665975 - Implement the math-style property. r=emilio
This patch renames the internal -moz-math-display to math-style and
exposes it under the layout.css.math-style.enabled preference. The
initial value becomes "normal" but that does not affect the default
MathML behavior since the UA style sheet sets the math-style property
explicitly on <math> tags. WPT tests are updated to use the syntax
approved by the CSSWG.

Intent to prototype: https://groups.google.com/forum/#!msg/mozilla.dev.platform/1hQQ7ISudGo/_yLEckEeBQAJ

Differential Revision: https://phabricator.services.mozilla.com/D90731
2020-09-21 05:41:51 +00:00
Razvan Caliman f36f05b770 Bug 1572662 - Clean-up SelectorHighlighter and clarify code comments r=jdescottes
Depends on D90245

Differential Revision: https://phabricator.services.mozilla.com/D90246
2020-09-16 10:09:11 +00:00
Razvan Caliman 020ea4af5e Bug 1572662 - Remove unused option to customize fill color on SelectorHighlighter and BoxModelHighlighter r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D90245
2020-09-16 13:43:57 +00:00
Razvan Caliman 8f69605f28 Bug 1665341 - Remove obsolete BoxModelRenderer. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D90402
2020-09-16 14:05:30 +00:00
Kriyszig d79006ce23 Bug 1653520 - Remove code replication in the compatibility actor by moving UserSettings to shared folder r=daisuke,mtigley,devtools-backward-compat-reviewers
Instead of replicationg the browser list fetch using the
preference on the server side, we send the browser list from the
client side to the CompatibilityActor to get the declaration block
compatibility issues.
This way the pref setting is retained completely on the client
side and server doesn't have code duplication.

Differential Revision: https://phabricator.services.mozilla.com/D87613
2020-09-15 14:26:39 +00:00
Kriyszig da1f86f883 Bug 1657537 - Part 2 - Move MDNCompatibility library and related files to devtools/server/actors/compatibility r=daisuke,mtigley
This moves the MDNCompatibility library and the related datasets
and tests to the server side. It also moves the compatibility actor
file intot he compatibility directory.
The links to these files have been updated and the library tests have
been moved to the new location.

Differential Revision: https://phabricator.services.mozilla.com/D86521
2020-09-15 14:26:36 +00:00
Kriyszig 4825b53af6 Bug 1657537 - Part 1 - Move the ISSUE_TYPE property to devtools/shared/constants.js r=mtigley
Most of the client side imports from the MDNCompatibility library
is to access the MDNCompatibility.ISSUE_TYPE property.
This patch moves the property into devtools/shared/constants.js
from where it can be accessed on both the client and server side.

Differential Revision: https://phabricator.services.mozilla.com/D86519
2020-09-15 14:26:23 +00:00
Daisuke Akatsuka aa9f77e93e Bug 1644193: Make walker.getStyleSheetOwnerNode() to reflect resource watcher. r=ochameau
Depends on D89282

Differential Revision: https://phabricator.services.mozilla.com/D89283
2020-09-14 23:37:39 +00:00
Daisuke Akatsuka 581ea9af20 Bug 1644193: Implement addStyleSheet function. r=ochameau,devtools-backward-compat-reviewers
Depends on D89280

Differential Revision: https://phabricator.services.mozilla.com/D89281
2020-09-14 23:37:39 +00:00
Daisuke Akatsuka eb8b319b2c Bug 1644193: Reflect added stylesheets. r=ochameau
Depends on D89277

Differential Revision: https://phabricator.services.mozilla.com/D89280
2020-09-11 08:11:08 +00:00
Daisuke Akatsuka 1a2e261447 Bug 1644193: Implement update function. r=ochameau
Depends on D88540

Differential Revision: https://phabricator.services.mozilla.com/D89277
2020-09-11 08:10:25 +00:00
Daisuke Akatsuka 3908e7a6d9 Bug 1644193: Implement basic server-side stylesheets watcher. r=ochameau
Depends on D88531

Differential Revision: https://phabricator.services.mozilla.com/D88540
2020-09-14 21:29:47 +00:00
Daisuke Akatsuka 3fd81e0284 Bug 1664842: Introduce async watch function. r=ochameau
Differential Revision: https://phabricator.services.mozilla.com/D88759
2020-09-14 21:12:52 +00:00
Julian Descottes ab325d894c Bug 1664437 - Fix uri logging in WindowGlobalLogger r=ochameau
Depends on D89909

Differential Revision: https://phabricator.services.mozilla.com/D89910
2020-09-14 17:02:31 +00:00
Julian Descottes 7ad7cc6bec Bug 1664437 - Update WindowGlobalLogger to format logs on several lines r=ochameau
Depends on D89908

Differential Revision: https://phabricator.services.mozilla.com/D89909
2020-09-14 17:01:46 +00:00
Julian Descottes 7bad920441 Bug 1664437 - Extract DevTools WindowGlobalLogger to a dedicated module r=ochameau
Differential Revision: https://phabricator.services.mozilla.com/D89908
2020-09-14 16:53:08 +00:00
Jan de Mooij 927eea2c81 Bug 1663847 part 2 - Change Debugger.Environment.callee getter to calleeScript getter. r=tcampbell,jdescottes
The callee getter returned |undefined| for certain functions because it's
hard to recover the callee consistently for all environments (and we can't
return the internal canonical function). See also bug 1414684.

This patch fixes that by exposing the script instead of the callee. Devtools is
only interested in the displayName and parameterNames properties and those are
also available on scripts (the previous patch adds Script.parameterNames).

Differential Revision: https://phabricator.services.mozilla.com/D89701
2020-09-11 09:24:34 +00:00
Julian Descottes a66edac6cb Bug 1663941 - Do not call onAvailable if cached server resources are empty r=ochameau
Depends on D89609

Differential Revision: https://phabricator.services.mozilla.com/D89611
2020-09-10 20:52:39 +00:00
Christoph Kerschbaumer af3ae708f9 Bug 1664177: Load all images in devtools/client/debugger/images using chrome:. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D89727
2020-09-10 17:04:35 +00:00
Razvan Caliman 8e4b6b2a5b Bug 1646028 - Add generic highlighter manager to HighlightersOverlay. r=ochameau
Depends on D81525

Introduced a centralized way in `HighlightersOverlay` to invoke highlighters by type, automatically managing previously active highlighters.

First some context.
`HighlightersOverlay` is a bit of a misnomer. It already does a few things:
- provides methods to manually invoke some highlighters (Flex/Grid/Shapes/BoxModel)
- provides a way to delegate mouse events from Rules view / Computed view / Markup and invoke highlighters based on the event's target node
- manages state of Flex/Grid highlighters to be able to restore them on page refresh
- exposes the node that is highlighted by a particular highlighter
- misc handlers for events that require hiding highlighters by type (ex mutation events)

The changes in this patch add the core functionality which will automatically manage the visibility of highlighters regardless of their node's host frame:
- `this._activeHighlighters` is a Map which maps a highlighter type to the currently visible highlighter instance and its corresponding `NodeFront`
- `showHighlighterTypeForNode(type, nodeFront, options)` invokes a highlighter type for a given `NodeFront` while toggling off any existing highlighter for that type. For situations where multiple highlighters of the same type can be visible at the same time (ex: Grid), this is where we could manage their visibility.
- `hideHighlighterType(type)` hides all highlighters of a given type; can be followed-up with a more specific `hideHighlighterTypeForNode()` when needed
- `getNodeForActiveHighlighter(type)` returns the `NodeFront` currently highlighted by a highlighter type. This is an abstracted replacement for `flexboxHighlighterShown`, `geometryEditorHighlighterShown`, etc.

##### Accommodation for tests

To mitigate the fact that many tests and some consumers expect [exact event names](https://searchfox.org/mozilla-central/search?path=&q=-highlighter-shown) to be fired, like "box-model-highlighter-shown", instead of generic shown/hidden events with the highlighter type property as event data, we introduce a temporary map, `HIGHLIGHTER_EVENTS`, from which we pick the event to fire according to the highlighter type. As we progress in refactoring, the intent is for this map to slowly go away.


##### Intent for refactoring

The intent is for all client-side consumers to invoke highlighters via these methods. For example:
```
this.inspector.highlighters.showHighlighterTypeForNode(
      "BoxModelHighlighter",
      nodeFront
    )
```

See another example of this in the migration of `FlexboxHighligther` in D79694.

##### Future plans

In the medium-term, it's likely we'll move this part of `HighligthersOverlay` from inspector to toolbox and rename it `HighlightersManager`. This way, other consumers, like Debugger and Console can also use it [instead of the existing approach](https://searchfox.org/mozilla-central/rev/027893497316897b8f292bde48dbb6da2391a331/devtools/client/framework/toolbox.js#3503-3557). Haven't attempted this yet. Pending updates to the Flexbox, Grid, Shapes and CSS Transform highlighters so when we migrate paths from `inspector.highlighters` to ️ `toolbox.highlighters` is done in one go for all tests and consumers.

Differential Revision: https://phabricator.services.mozilla.com/D81526
2020-09-10 12:00:34 +00:00
Emilio Cobos Álvarez a3c20c9800 Bug 1662703 - Make appearance: button behave like auto. r=heycam
As per https://github.com/w3c/csswg-drafts/issues/5174.

Differential Revision: https://phabricator.services.mozilla.com/D89119
2020-09-10 08:58:09 +00:00
Razvan Maries f0ac3ad62a Backed out changeset baab244deeb0 (bug 1662703) for perma failures on 482681.xhtml. CLOSED TREE 2020-09-10 04:50:23 +03:00
Emilio Cobos Álvarez af8bc3472b Bug 1662703 - Make appearance: button behave like auto. r=heycam
As per https://github.com/w3c/csswg-drafts/issues/5174.

Differential Revision: https://phabricator.services.mozilla.com/D89119
2020-09-08 23:03:58 +00:00
Julian Descottes fde673f31c Bug 1635461 - Remove watcher logic from Walker Actor r=ochameau,devtools-backward-compat-reviewers
Depends on D86163

Differential Revision: https://phabricator.services.mozilla.com/D86549
2020-09-09 17:14:07 +00:00
Julian Descottes 7909e64490 Bug 1635461 - Remove watcher logic from WalkerFront in favor of ResourceWatcher r=ochameau
Depends on D86162
The resource watcher already guarantees that listeners are only called once, caches resources etc.
Consequently, the client side logic currently implemented in the WalkerFront is redundant and should be removed.

Differential Revision: https://phabricator.services.mozilla.com/D86163
2020-09-09 16:08:56 +00:00
Julian Descottes 2eb6d9ccce Bug 1635461 - Use ResourceWatcher for root-node resources in tests r=ochameau
Depends on D86160

Differential Revision: https://phabricator.services.mozilla.com/D86162
2020-09-09 16:08:38 +00:00
Alexandre Poirot 550422b87a Bug 1663636 - Prevent trying to resume destroyed documents. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D89450
2020-09-08 16:31:01 +00:00
Brad Werth fc3cb8fd99 Bug 1661283 Part 6: Add a test of NodeActor.isScrollable on various elements. r=gl
Differential Revision: https://phabricator.services.mozilla.com/D88683
2020-08-31 17:56:24 +00:00
Brad Werth 8ca8fd6962 Bug 1661283 Part 5: Add a test of GetOverflowingChildrenOfElement on the body element. r=gl
Differential Revision: https://phabricator.services.mozilla.com/D88682
2020-09-04 13:15:08 +00:00
Brad Werth ccf873b003 Bug 1661283 Part 4: Make NodeActor.initialize respect overflow debugging pref. r=gl
This also reuses a cached result of isScrollable, to avoid a second call.

Differential Revision: https://phabricator.services.mozilla.com/D88507
2020-09-02 23:52:37 +00:00
Brad Werth 75102cef12 Bug 1661283 Part 3: Make NodeActor.isScrollable use the new Element.hasVisibleScrollbars method. r=gl
This removes the need for the document/dom walk.

Differential Revision: https://phabricator.services.mozilla.com/D88506
2020-08-28 22:18:34 +00:00
Alexandre Poirot 1b5d072163 Bug 1662126 - Make synchronization code related to resourceTypes reusable. r=nchevobbe
The idea here is to reuse this to communicate the breakpoints (and many other things).

Differential Revision: https://phabricator.services.mozilla.com/D88849
2020-09-07 08:32:44 +00:00
Alexandre Poirot 04f81fed65 Bug 1662126 - Share code in WatcherRegistry between targets and resouces. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D88848
2020-09-07 08:32:37 +00:00
Alexandre Poirot acd17d815f Bug 1662126 - Convert WatcherRegistry Set to Arrays. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D88847
2020-09-07 08:32:34 +00:00
Julian Descottes 3a577649e6 Bug 1662067 - Set default preferences from about:debugging when connecting to remote runtimes r=daisuke,nchevobbe,devtools-backward-compat-reviewers
At the moment, it is easy to break remote debugging by reading preferences incorrectly.
Typically, creating a preference in the firefox preference index file will only create it for Firefox, not for mobile (Fenix).
When trying to read the preference from the server with the Services.prefs.get*Pref APIs, the call will throw unless a fallback value was specified.

A longer term solution is investigated at https://bugzilla.mozilla.org/show_bug.cgi?id=1660182, but for now this changeset allows about:debugging to set a few default values for preferences when connecting to a remote runtime.

Differential Revision: https://phabricator.services.mozilla.com/D88782
2020-09-03 07:49:33 +00:00
Nicolas Chevobbe 317a7ff2c2 Bug 1660466 - Fix attaching target/thread test intermittents. r=jdescottes.
Move the function taking care of closing the Browser Console to shared-head so
we can close it before closing the tabs opened during the test.

While attaching the worker, check that the Worker Debugger isn't closed, and
if it is, reject the promise. On the target list, catch rejection while attaching
and simply bail out so we don't call the rest of the code in onTargetAvailable.

Those guards are not enough to prevent any failure while attaching, so we're
wrapping calls to `attachAndInitThread`/`_onThreadInitialized` in try/catch
blocks to avoid test failures.

Differential Revision: https://phabricator.services.mozilla.com/D88766
2020-09-02 14:43:23 +00:00
Hubert Boma Manilla 87bd8a1f81 Bug 1644191 - Server side network events listening r=nchevobbe,ochameau
Differential Revision: https://phabricator.services.mozilla.com/D78867
2020-09-02 13:31:59 +00:00
Alexandre Poirot 2452f172af Bug 1661627 - Stop ignoring PDF print preview documents. r=nchevobbe
PDF print preview are using about:blank documents, which are ignored
by DevTools in order to save resources.
We avoid creating targets for these, very often, transcient documents.
I tried to find ways to distinguish typical temporary about:blank documents
from this print preview one.

Differential Revision: https://phabricator.services.mozilla.com/D88956
2020-09-02 07:38:59 +00:00
Emilio Cobos Álvarez 03baee9d8a Bug 1662478 - Rename ::file-chooser-button to ::file-selector-button, and enable it in all channels. r=jwatt
See https://github.com/w3c/csswg-drafts/issues/5049

Differential Revision: https://phabricator.services.mozilla.com/D88995
2020-09-01 22:58:10 +00:00
Daisuke Akatsuka b9e65b07d6 Bug 1659589: Implement update method in stylesheets actor. r=ochameau,devtools-backward-compat-reviewers
Depends on D87046

Differential Revision: https://phabricator.services.mozilla.com/D87047
2020-08-28 06:27:53 +00:00
Daisuke Akatsuka e9b12ccb1d Bug 1659589: Implement getText in stylesheets actor. r=ochameau,devtools-backward-compat-reviewers
Depends on D87044

Differential Revision: https://phabricator.services.mozilla.com/D87045
2020-08-28 06:07:33 +00:00
Daisuke Akatsuka f8c36ace27 Bug 1659589: Implement toggleDisabled in stylesheets actor. r=ochameau,devtools-backward-compat-reviewers
Depends on D87043

Differential Revision: https://phabricator.services.mozilla.com/D87044
2020-08-20 08:27:47 +00:00
Julian Descottes 4d4be17fbc Bug 1662058 - Add fallback to get pref devtools.overflow.debugging.enabled from server r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D88767
2020-08-31 08:37:13 +00:00
Alexandre Poirot 45a188bf6b Bug 1661569 - Avoid mixing target actor of the many toolboxes. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D88486
2020-08-28 05:48:53 +00:00
Daisuke Akatsuka a936229ca0 Bug 1659589: Get property-change event via resource watcher. r=ochameau
Depends on D87041

Differential Revision: https://phabricator.services.mozilla.com/D87042
2020-08-26 08:37:18 +00:00
Daisuke Akatsuka 0adc3db50a Bug 1659589: Handle importing stylesheet from file using resource watcher mechanism to keep consistency. r=ochameau,devtools-backward-compat-reviewers,jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D87040
2020-08-27 22:31:52 +00:00
Alexandre Poirot 2effa77867 Bug 1660895 - Eagerly ignore loading or destroying documents. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D88075
2020-08-26 20:31:57 +00:00
Alexandre Poirot 07e7e6e9b1 Bug 1660892 - Ignore window objects related to remote iframes in thread actor. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D88074
2020-08-26 14:25:31 +00:00
Mihai Alexandru Michis 01a6dfae9d Backed out changeset 9d95edbd8386 (bug 1660892) for causing devtool timeouts.
CLOSED TREE
2020-08-26 15:39:48 +03:00
Alexandre Poirot 6238cd4670 Bug 1660892 - Ignore window objects related to remote iframes in thread actor. r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D88074
2020-08-26 08:48:23 +00:00
Nicolas Chevobbe aaa2b8be93 Bug 1659376 - Fix Browser Toolbox inspector when print preview is displayed.r=rcaliman.
The issue was that the getHighlighter request for the about:printpreview
target never settled. It appears that the document always stays in an
unitialized readyState, which was causing trouble.
Instead of relying only on readyState, we now call isDocumentReady, which
also checks if the document is loading.

Differential Revision: https://phabricator.services.mozilla.com/D87756
2020-08-25 07:08:12 +00:00
Nicolas Chevobbe a00c418cc2 Bug 1659376 - Extract isDocumentReady from WalkerActor to inspector utils file. r=rcaliman.
Differential Revision: https://phabricator.services.mozilla.com/D87755
2020-08-25 07:07:48 +00:00
manas 68019d8bda Bug 1660266 - Encapsulate the code for finding overflow causing elements inside the Overflow Debugging pref. r=gl
Differential Revision: https://phabricator.services.mozilla.com/D87926
2020-08-23 23:05:13 +00:00
Razvan Maries 5dd733dcb0 Backed out changeset 11f769ec943d (bug 1660266) for perma failures on browser_markup_overflow_badge.js. CLOSED TREE 2020-08-22 21:58:24 +03:00
manas 4ef56c529d Bug 1660266 - Encapsulate the code for finding overflow causing elements inside the Overflow Debugging pref. r=gl
Differential Revision: https://phabricator.services.mozilla.com/D87926
2020-08-22 16:57:04 +00:00
manas 071d9177e5 Bug 1657680 - Make the scrollable badge clickable and add click handler. r=gl,jdescottes,bradwerth
Differential Revision: https://phabricator.services.mozilla.com/D86245
2020-08-22 09:12:12 +00:00
Narcis Beleuzu 4751b29785 Backed out changeset ed74d4e4b273 (bug 1657680) for dt failure on browser_markup_overflow_badge.js 2020-08-22 04:42:50 +03:00
manas 88e461c163 Bug 1657680 - Make the scrollable badge clickable and add click handler. r=gl,jdescottes,bradwerth
Differential Revision: https://phabricator.services.mozilla.com/D86245
2020-08-21 22:27:18 +00:00
Narcis Beleuzu cb798e0f9e Backed out 2 changesets (bug 1659376) for dt failures on browser_dbg-content-script-sources.js. CLOSED TREE
Backed out changeset 61e3dea03a62 (bug 1659376)
Backed out changeset 86e77b35c75d (bug 1659376)
2020-08-21 20:47:02 +03:00
Nicolas Chevobbe 0cd6331277 Bug 1659376 - Fix Browser Toolbox inspector when print preview is displayed.r=rcaliman.
The issue was that the getHighlighter request for the about:printpreview
target never settled. It appears that the document always stays in an
unitialized readyState, which was causing trouble.
Instead of relying only on readyState, we now call isDocumentReady, which
also checks if the document is loading.

Differential Revision: https://phabricator.services.mozilla.com/D87756
2020-08-21 11:56:51 +00:00
Nicolas Chevobbe f9dc6cb44b Bug 1659376 - Extract isDocumentReady from WalkerActor to inspector utils file. r=rcaliman.
Differential Revision: https://phabricator.services.mozilla.com/D87755
2020-08-21 11:56:48 +00:00
Julian Descottes 8853c00813 Bug 1659866 - Move server-side devtools pref for Compatibility panel to modules/libpref/init/all.js r=daisuke
Depends on D87603

Differential Revision: https://phabricator.services.mozilla.com/D87611
2020-08-19 22:34:22 +00:00
Bogdan Tara 789e572738 Backed out changeset c209cb1c0341 (bug 1658146) for browser_resources_network_events.js failures CLOSED TREE 2020-08-20 03:17:05 +03:00
Hubert Boma Manilla 75bcf1cab2 Bug 1658146 - Stop request blocking for no valid reason r=Honza
Differential Revision: https://phabricator.services.mozilla.com/D87569
2020-08-19 14:13:48 +00:00
Julian Descottes 8aecb1e6df Bug 1642295 - Enable server side resource watching by default r=ochameau
Depends on D86963

Just for reference for now, since this is incompatible with target switching.

Differential Revision: https://phabricator.services.mozilla.com/D86964
2020-08-19 14:08:40 +00:00
Julian Descottes e9bb161639 Bug 1642295 - Fold clearCachedMessage from ConsoleServiceListener into WebConsoleActor r=nchevobbe
Depends on D86961

Differential Revision: https://phabricator.services.mozilla.com/D86962
2020-08-19 14:08:37 +00:00
Julian Descottes 3507a935c3 Bug 1642295 - Fix shouldHandleMessage signature in platform-message DevTools resource r=nchevobbe
Depends on D86960

Differential Revision: https://phabricator.services.mozilla.com/D86961
2020-08-19 14:08:36 +00:00
Julian Descottes 2703786741 Bug 1642295 - Add missing Cu import in devtools/server/actors/object/utils.js r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D86960
2020-08-19 14:08:36 +00:00
Nicolas Chevobbe 4024f7b515 Bug 1659407 - Remove newCacheStructure webconsole trait. r=ladybenko.
Differential Revision: https://phabricator.services.mozilla.com/D87234
2020-08-18 15:11:59 +00:00
Julian Descottes 1ecab54df3 Bug 1658888 - Remove old backward compat code for ArrayBuffer marshalling r=ochameau,devtools-backward-compat-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D86947
2020-08-17 18:35:18 +00:00
Kris Maglione 0c976d908a Bug 1651519: Part 2 - Also remove nsIDOMWindowUtils::outerWindowID. r=nika,geckoview-reviewers,agi
Differential Revision: https://phabricator.services.mozilla.com/D82957
2020-08-17 20:22:12 +00:00
Kris Maglione 3af8c4138c Bug 1651519: Remove nsIDOMWindowUtils::currentInnerWindowID. r=nika,remote-protocol-reviewers,webcompat-reviewers,whimboo
It has some properties which make it footgunny, especially in the face of
Fission. Callers should use WindowGlobalChild.innerWindowId instead.

Differential Revision: https://phabricator.services.mozilla.com/D82801
2020-08-17 20:20:50 +00:00
Nicolas Chevobbe 5c09051944 Bug 1658945 - Add getResourceTypeDictionaryForTargetType function in devtools/server/actors/resources/index.js. r=ochameau.
We already had a function that was returning a resourceType dictionnary for
a given watcher or target actor, on which we were then checking the targetType
to return the appropriate dictionnary.
It feels appropriate to have a dedicated function to get the dictionnary from
the targetType only, so we can call it from other places instead of repeating
the same instructions.

Differential Revision: https://phabricator.services.mozilla.com/D86979
2020-08-14 05:09:02 +00:00
Christoph Kerschbaumer bc8e540bb5 Bug 1658323: HTTPS-Only Mode: Have console message link to SUMO page r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D86577
2020-08-11 13:22:32 +00:00
Alexandre Poirot 2cee1e6ebe Bug 1657105 - Fix server side update and destroy events. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D86048
2020-08-12 16:49:25 +00:00
Alexandre Poirot 3441a8b394 Bug 1657105 - Allow listening for resources from both parent and content processes. r=jdescottes,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D86046
2020-08-12 16:49:23 +00:00
Alexandre Poirot 9f9a8d9b3e Bug 1657105 - Use constants to define target types on the server and set targetType on all targets. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D86632
2020-08-12 16:49:21 +00:00
Alexandre Poirot c5b1ffc8f8 Bug 1658566 - Remove all unecessary typeName. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D86722
2020-08-12 16:57:05 +00:00
Bogdan Tara 16fadcf1aa Backed out 3 changesets (bug 1657105) for es lint and test_logpoint-03.js failures CLOSED TREE
Backed out changeset e0ac6c61d65a (bug 1657105)
Backed out changeset 51b8364f941b (bug 1657105)
Backed out changeset cc50fc1340a9 (bug 1657105)
2020-08-12 18:56:52 +03:00
Alexandre Poirot feeba49b58 Bug 1657105 - Fix server side update and destroy events. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D86048
2020-08-11 14:15:18 +00:00
Alexandre Poirot 3bf66fff0b Bug 1657105 - Allow listening for resources from both parent and content processes. r=jdescottes,nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D86046
2020-08-11 14:11:52 +00:00
Alexandre Poirot f4606b2122 Bug 1657105 - Use constants to define target types on the server and set targetType on all targets. r=jdescottes
Differential Revision: https://phabricator.services.mozilla.com/D86632
2020-08-12 15:10:13 +00:00
Julian Descottes f05829aa08 Bug 1629890 - Use Front/Actor::isDestroyed to replace actorID checks r=nchevobbe
Depends on D86325

Differential Revision: https://phabricator.services.mozilla.com/D86356
2020-08-12 11:33:44 +00:00
Julian Descottes 028ab078d0 Bug 1629890 - Convert accessible isDestroyed getter to Actor::isDestroyed() r=yzen,nchevobbe
Depends on D86324

Differential Revision: https://phabricator.services.mozilla.com/D86325
2020-08-10 18:56:38 +00:00
Noemi Erli 56b4ff381b Backed out changeset 9040cdaddc7c (bug 1658323) for causing multiple failures actors/webconsole related CLOSED TREE 2020-08-11 14:45:36 +03:00
Christoph Kerschbaumer a2f94da3d9 Bug 1658323: HTTPS-Only Mode: Have console message link to SUMO page r=nchevobbe
Differential Revision: https://phabricator.services.mozilla.com/D86577
2020-08-11 10:00:53 +00:00
Daisuke Akatsuka d9acff03ab Bug 1644194: Implement CSS change watcher. r=ochameau
Differential Revision: https://phabricator.services.mozilla.com/D85239
2020-08-10 23:32:28 +00:00
Butkovits Atila 6c59af367d Backed out changeset cfaf03474399 (bug 1651033) for failure at browser_accessibility_walker.js. CLOSED TREE 2020-08-10 19:28:49 +03:00
Julian Descottes a0acf13c9c Bug 1651033 - Prevent default for pointerup/down events with DevTools node picker r=gl
Differential Revision: https://phabricator.services.mozilla.com/D86502
2020-08-10 14:37:50 +00:00
Julian Descottes 6e5145a87c Bug 1652445 - Use root node resource to detect navigation for all frames r=rcaliman,ochameau
Depends on D85599

The WalkerActor is currently responsible for watching navigations and exposes them to the client.
However, this is communicated to the client differently depending on what kind of frame navigates.
If the top frame of the target navigates, this will be exposed via the watchRootNode API (onDestroyed/onAvailable callbacks will be triggered)
If an inner frame navigates, mutations will be emitted: "frameLoad"/"documentUnload" + a fake "childList" mutation.

On the client side, we have to handle both very similarly which leads to some duplication.
Also "frameLoad"/"documentUnload" are one of the last "immediateMutations" which usually means they should not have been mutations in the first place.

The goal here is to use the watchRootNode API for all frames.

Differential Revision: https://phabricator.services.mozilla.com/D84973
2020-08-07 12:16:51 +00:00
Julian Descottes 40eb2a0d73 Bug 1652445 - Remove skipped & outdated test browser_inspector-mutations-frameload.js r=ochameau
Depends on D85598

This test relies on mutations which are no longer emitted for most navigations and which will no longer be emitted at all with the next patches.
It has been disabled for 9 months and should be removed.

Differential Revision: https://phabricator.services.mozilla.com/D85599
2020-08-07 12:16:44 +00:00
Julian Descottes 58de59ca2b Bug 1652445 - Remove backward compatibility code for newRoot mutations r=rcaliman
Depends on D85597

newRoot mutations are no longer emitted by any server we support, we can remove the corresponding client code.

Differential Revision: https://phabricator.services.mozilla.com/D85598
2020-08-07 12:16:42 +00:00
Julian Descottes efef5c970b Bug 1652445 - Remove outdated traits from NodeActor r=rcaliman
Depends on D84972

Differential Revision: https://phabricator.services.mozilla.com/D85597
2020-08-07 12:15:02 +00:00
Julian Descottes 1d0130e4df Bug 1652445 - Rename WalkerActor _ref method and _refMap property r=gl
_ref is renamed to _getOrCreateNodeActor to better reflect the purpose of the method.
_refMap is renamed to _nodeActorsMap

The test helper inspector-helpers was also directly querying _refMap.
This has been replaced by a call to the public API getNode.

Differential Revision: https://phabricator.services.mozilla.com/D84972
2020-08-07 12:14:37 +00:00