Bug 1551378 Comment 5 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

(In reply to Krzysztof Jan Modras from comment #3)
> I think my changes in https://bugzilla.mozilla.org/show_bug.cgi?id=1539144 make `tabs.query` to work correctly. Assumption is that every GeckoSession represents a Gecko window with exactly one tab.

Yep, that should be correct.

(In reply to Krzysztof Jan Modras from comment #4)
> (In reply to Krzysztof Jan Modras from comment #3)
> > I think my changes in https://bugzilla.mozilla.org/show_bug.cgi?id=1539144 make `tabs.query` to work correctly. Assumption is that every GeckoSession represents a Gecko window with exactly one tab.
> 
> That approach holds only in case all sessions are loaded in GeckoView - I can imagine an application that holds unused session out side of GeckoView util they get accessed by the user, in such case `tabs.query` will fail to return information about them. 
> A more GeckoView-like approach would be to delegate `tabs.query` to GeckoRuntime so application can decide which tabs are available. 
> 
> In addon perspective the first approach should be good enough for now as addons should probably only interact with tabs that are currently in use, but behavior may be problematic to expecting it developers.

I think it's OK to ignore `GeckoSession`s that are not attached to a `GeckoView`, especially for MVP. If there's a clear need / usecase for it we can discuss it in a separate bug.
(In reply to Krzysztof Jan Modras from comment #3)
> I think my changes in https://bugzilla.mozilla.org/show_bug.cgi?id=1539144 make `tabs.query` to work correctly. Assumption is that every GeckoSession represents a Gecko window with exactly one tab.

Yep, that should be correct.

(In reply to Krzysztof Jan Modras from comment #4)
> That approach holds only in case all sessions are loaded in GeckoView - I can imagine an application that holds unused session out side of GeckoView util they get accessed by the user, in such case `tabs.query` will fail to return information about them. 
> A more GeckoView-like approach would be to delegate `tabs.query` to GeckoRuntime so application can decide which tabs are available. 
> 
> In addon perspective the first approach should be good enough for now as addons should probably only interact with tabs that are currently in use, but behavior may be problematic to expecting it developers.

I think it's OK to ignore `GeckoSession`s that are not attached to a `GeckoView`, especially for MVP. If there's a clear need / usecase for it we can discuss it in a separate bug.

Back to Bug 1551378 Comment 5