catacombing / kumo

A Wayland Mobile Browser
GNU General Public License v3.0
8 stars 1 forks source link

Jump to last tab after closing current one #9

Closed chrisduerr closed 2 months ago

chrisduerr commented 2 months ago

Currently when the active tab is closed, we jump to the first tab. However in the tabs list that tab is at the exact opposite position from the active tab. To jump as little as possible, it probably makes more sense to jump to the last open tab after closing.

One alternative to ensure staying even closer is to jump to the next/previous tab. Firefox seems to always jump to the next tab in the list, so maybe that's the best choice. Though chances are jumping to the previous tab is just as correct.

Jumping to the next one makes sense for Firefox since that keeps the active tab in the same location, however since our tab view is in reverse order, maybe jumping to the previous one is the better way to get the same behavior.