+ We use to show tabcandy whenever we closed any tab. We now only focus tabcandy when the last tab in a group is closed.

+ TODO: Ideally, we should have an animation of the last tab be zoomed out into the tabcandy interface, and then that tab fading away along with the group (if the group is unnamed).
This commit is contained in:
Aza Raskin 2010-04-30 23:50:43 -07:00
parent 064ee2bebe
commit a3f0f48fd1
2 changed files with 12 additions and 2 deletions

View File

@ -104,6 +104,11 @@ var Tabbar = {
window.Page = {
startX: 30,
startY: 70,
show: function(){
Utils.homeTab.focus();
UI.tabBar.hide(false);
},
// ----------
init: function() {
@ -111,7 +116,12 @@ window.Page = {
Utils.homeTab.raw.minWidth = 60;
Tabs.onClose(function(){
Utils.homeTab.focus();
// Only go back to the TabCandy tab when there you close the last
// tab of a group.
var group = Groups.getActiveGroup();
if( group && group._children.length == 0 ){
Page.show();
}
Toolbar.unread = 0;
return false;
});

View File

@ -242,7 +242,7 @@ var Utils = {
return null;
},
// ___ Files
getInstallDirectory: function(id) {
var file = extensionManager.getInstallLocation(id).getItemFile(id, "install.rdf");