Open Bug 1388276 Opened 2 years ago Updated 2 months ago

moving a tab to an index that is a pinned tab adds to end of tab strip instead of next valid index


(WebExtensions :: General, enhancement, P5)



(Not tracked)


(Reporter: dietrich, Unassigned)


Setting a tab index to a value that's lower than the index of the last-pinned-tab puts the tab at the end of the tab strip instead of after the last-pinned-tab.

Basically just throwing up our hands instead of doing the expected behavior.

We should instead move the tab to the first index after the last pinned tab.
Hrm, just found bug 1248093. This is a more general case.

I think we should fix this because the intent of the developer is clear, and how we handle it is counter-intuitive.

We shouldn't have to match Chrome's behavior when their behavior is poor error handling.

Also, given Will's test about how the index passed to the event handler is the expected index given a behavior where the tab is placed after the last pinned tab, it might actually be a bug in Chrome's implementation.
Things are getting weirder.

If I pass an index of a pinned tab, the success handler is called with zero tabs as parameter and the error handler is not called.

This really should be an error state, if we're putting the tab in a place where the developer didn't ask.
Priority: -- → P5
Product: Toolkit → WebExtensions
You need to log in before you can comment on or make changes to this bug.