Support target-switching without a toolbox
Categories
(DevTools :: Framework, enhancement)
Tracking
(Fission Milestone:M7, firefox80 fixed)
Tracking | Status | |
---|---|---|
firefox80 | --- | fixed |
People
(Reporter: ochameau, Assigned: ochameau)
References
(Blocks 2 open bugs)
Details
(Whiteboard: dt-fission-m2-reserve)
Attachments
(4 files)
Bug 1644360's review highlighted that we do not properly support target-switching in tests that are covering TargetList/ResourceWatcher without a toolbox.
It would be helpful for test to make it so that LocalTabTarget's onRemotenessChange method does update the new top level target, even if there is no toolbox.
Doing this would actually be yet another step toward bug 1644397.
New top level target should eventually be emitted by the server, from the Watcher actor and should be received as any other target, via target-available-form.
Assignee | ||
Comment 1•4 years ago
|
||
Target switching should be implemented differently.
I think switchToTarget may have been introduce before TargetList?
But top level target switching should be handled via onTargetAvailable.
It happens when onTargetAvailable is called with a targetFront with isTopLevel=true,
and isTargetSwitching argument is true.
Assignee | ||
Comment 2•4 years ago
|
||
In a near future, target switching should be notified by the watcher actor,
via a target-available-form event.
So that all the logic around target switching should rather be into this RDP event listener.
Assignee | ||
Comment 3•4 years ago
|
||
We don't have to and shouldn't unregister and re-register the Watcher actor listeners
in case of top level target switching. As, Watcher actor is independant from the top level target
and we might loose some events by doing so. One main goal of Watcher actor was about that.
Being independant from the lifecycle of the top level target.
Assignee | ||
Comment 4•4 years ago
|
||
We might be able to move even more code from LocalTabTarget to TargetList,
but here is the minimal modification, which allows to update the target,
without requiring a Toolbox.
Updated•4 years ago
|
Comment 5•4 years ago
|
||
Tracking dt-fission-m2-reserve bugs for Fission Beta milestone (M7).
Assignee | ||
Comment 6•4 years ago
|
||
Pushed by apoirot@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/ab3aa936b9bf Merge Toolbox.switchToTarget into Toolbox._onTargetAvailable. r=jdescottes https://hg.mozilla.org/integration/autoland/rev/d59aca70d9a7 Merge most of TargetList.switchToTarget into TargetList._onTargetAvailable. r=jdescottes https://hg.mozilla.org/integration/autoland/rev/2316b38ce191 Only stop and start listening to legacy listeners in case of top level target switching. r=jdescottes https://hg.mozilla.org/integration/autoland/rev/56af0aa5f116 Support target-switching without a toolbox. r=jdescottes
Comment 8•4 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/ab3aa936b9bf
https://hg.mozilla.org/mozilla-central/rev/d59aca70d9a7
https://hg.mozilla.org/mozilla-central/rev/2316b38ce191
https://hg.mozilla.org/mozilla-central/rev/56af0aa5f116
Description
•