Skip to content

Commit

Permalink
Bug 726560 - v4: commenting, let it undefined in gecko 1.x
Browse files Browse the repository at this point in the history
  • Loading branch information
xabolcs committed Mar 20, 2012
1 parent 5e5edaf commit e11907e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
6 changes: 4 additions & 2 deletions extension/chrome/content/browser.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,11 @@ get tabTitle() {
},

get tabGroupTitle() {
if (typeof(nightlyApp.getTabGroupTitle) === "function")
try
{
return nightlyApp.getTabGroupTitle(window);
return "";
}
catch (e) { }
},

init: function()
Expand Down
6 changes: 3 additions & 3 deletions extension/modules/tabGroupTitle.jsm
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ let sstore = Cc["@mozilla.org/browser/sessionstore;1"].getService(Ci.nsISessionS


/**
* Simply retrieves the active tabgroup's title from sessionStore
* Simply retrieves the active tabgroup's title from SessionStore
*/
function getActiveGroupName(win) {
let data = "", groupTitle = "";
Expand All @@ -34,15 +34,15 @@ function getActiveGroupName(win) {
*
* In Gecko 1.x title is set to "Undefined" as in other Apps
* Before FF10 title is managed by TabView
* After that we manages the title: SessionStore to load and save, borrowed code to generate
* After that we manages the title: using SessionStore and other borrowed code to generate
*/
function getTabGroupTitle(win) {
let nightlyApp = win.nightlyApp;
let TabView = win.TabView;

// TabView isn't implemented
if (!("TabView" in win))
return "";
return;

// If we are before Bug 682996,
// use TabView's own implementation except it is null
Expand Down

0 comments on commit e11907e

Please sign in to comment.