Closed Bug 1400955 Opened 7 years ago Closed 4 years ago

Dispatch JS tab events without depending on a <browser> being present

Categories

(Firefox for Android Graveyard :: General, enhancement, P5)

All
Android
enhancement

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: JanH, Unassigned)

References

Details

As described in bug 1343090 comment 5: We don't have any XUL-side <tab>s (since that part of our UI is implemented natively in Java, so at a first glance we don't have any need of them), so unlike Desktop we dispatch any JS-side tab events via the individual <browser> element itself, which naturally poses a problem if we're attempting to make lazily-loaded ("zombified") tabs completely <browser>-less. This is also causing some problems even today, because tab zombification already involves destroying the original <browser> and replacing it by a fresh one showing about:blank [1], so everybody listening to events on the old browser needs to listen to the corresponding tab zombification events and then move their event listeners across - failure to do so led e.g. to the infamous session history loss in bug 1044556. I'm not sure what the best solution here would be - my naive solution would be creating an additional <tabs> element with corresponding <tab> children that would be solely used for dispatching and listening to tab events, so anybody listening to (or wanting to dispatch) tab events would be totally unaffected by whatever unspeakable things we'd be doing to the actual <browser> element. [1] https://dxr.mozilla.org/mozilla-central/rev/ae39864562c6048fdc2950c5dfedb48e247c3300/mobile/android/chrome/content/browser.js#3827
Re-triaging per https://bugzilla.mozilla.org/show_bug.cgi?id=1473195 Needinfo :susheel if you think this bug should be re-triaged.
Priority: P3 → P5
We have completed our launch of our new Firefox on Android. The development of the new versions use GitHub for issue tracking. If the bug report still reproduces in a current version of [Firefox on Android nightly](https://play.google.com/store/apps/details?id=org.mozilla.fenix) an issue can be reported at the [Fenix GitHub project](https://github.com/mozilla-mobile/fenix/). If you want to discuss your report please use [Mozilla's chat](https://wiki.mozilla.org/Matrix#Connect_to_Matrix) server https://chat.mozilla.org and join the [#fenix](https://chat.mozilla.org/#/room/#fenix:mozilla.org) channel.
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → INCOMPLETE
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.