What happens when you close a tab in the Firefox web browser? If only one tab is open, Firefox will close. If multiple tabs are open, Firefox will open the last activate tab in the browser provided there was one.
If there was none, Firefox will load the tab to the left of the closed tab or the tab to the right depending on the closed tabs position in the tab bar of the browser.
While you can prevent Firefox from closing windows when the last tab is closed, by setting browser.tabs.closeWindowWithLastTab to false on about:config, it is not possible to change the order which Firefox consults to decide which tab to activate when a tab is closed.
Select After Closing Current
Select After Closing Current is a Firefox extension that gives users full control of the order when a new tab needs to be activated because the current one is closed.
The extension displays Firefox’s default order in the interface after installation; means, nothing changes right after installation. You need to open the extension’s settings, by loading about:addons and clicking on options next to Select After Closing Current, to change the order.
You can add and remove entries from the list of actions. The extension checks each starting with the one at the top and selects the first that matches the situation.
This looks like the following for the default configuration:
- If there is a last accessed tab, select it.
- If there is none, select the tab to the left of the closed one.
- If there is none, select the tab to the right of the closed one.
The extension supports the following options:
- Position: first, last, left, or right.
- Relation: tab, last accessed tab, parent tab, sibling tab, child tab, unread tab, unread child tab.
You combine position with relation to create new rules. Some examples:
- open the first unread tab.
- open the first unread sibling tab.
- open the first unread tab to the right.
- open the last child tab.
Use the up and down arrow buttons to move a rule and change the order of all rules in the process.
Select After Closing Current supports five keyboard shortcuts that you can configure. Select a key on the keyboard and modifiers, and assign each shortcut to a particular rule. Each shortcut closes the current tab and activates the assigned rule afterward.
Closing Words and verdict
Select After Closing Current is a useful extension for the Firefox web browser to change processing rules when a tab is closed in the Firefox web browser. The option to assign shortcuts to specific rules is handy as well as it ensures that the particular rule is executed provided that it is possible.
Ghacks needs you. You can find out how to support us here or support the site directly by becoming a Patreon. Thank you for being a Ghacks reader. The post Configure what Firefox does when you close a tab appeared first on gHacks Technology News.