Skip to content

Commit 0d849be

Browse files
author
Jehan
committed
Bug 847: tabcount in status line wrong when using several tab groups.
The total count shown in the status line is the total number of tabs in the session (not only in the current tab group); and the current tab index would be the index in that full tab list. Fixes issue 847
1 parent 7cbeb8f commit 0d849be

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

common/content/tabs.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ const Tabs = Module("tabs", {
6161
/**
6262
* @property {number} The number of tabs in the current window.
6363
*/
64-
get count() config.tabbrowser.mTabs.length,
64+
get count() config.tabbrowser.visibleTabs.length,
6565

6666
/**
6767
* @property {Object} The local options store for the current tab.
@@ -115,9 +115,9 @@ const Tabs = Module("tabs", {
115115
*/
116116
index: function (tab) {
117117
if (tab)
118-
return Array.indexOf(config.tabbrowser.mTabs, tab);
118+
return Array.indexOf(config.tabbrowser.visibleTabs, tab);
119119
else
120-
return config.tabbrowser.mTabContainer.selectedIndex;
120+
return Array.indexOf(config.tabbrowser.visibleTabs, config.tabbrowser.tabContainer.selectedItem);
121121
},
122122

123123
// TODO: implement filter

vimperator/NEWS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
2013-XX-XX:
22
* version 3.8
33
* Add "ssl" field shows SSL connection icon to "status" option (default: off)
4+
* Tabs count and it's index in status-line are changed to the current group's tabs count and it's index.
45

56
2013-05-22:
67
* version 3.7.1

0 commit comments

Comments
 (0)