From 4c2258c2fa0789e7c7b019df6bfb4c3e076a7e0a Mon Sep 17 00:00:00 2001 From: Aza Raskin Date: Sat, 22 May 2010 11:42:23 -0700 Subject: [PATCH] + Better indication of groups as drop targets + Using the new-tab buttons no longer cause a jarring shift due to window chrome appearing. --- browser/base/content/tabcandy/app/groups.js | 15 +++++++++++---- .../pinstripe/browser/tabcandy/tabcandy.css | 2 +- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/browser/base/content/tabcandy/app/groups.js b/browser/base/content/tabcandy/app/groups.js index 2986062781b5..de0097c24ada 100644 --- a/browser/base/content/tabcandy/app/groups.js +++ b/browser/base/content/tabcandy/app/groups.js @@ -932,8 +932,16 @@ window.Group.prototype = $.extend(new Item(), new Subscribable(), { // ---------- newTab: function() { Groups.setActiveGroup(this); - var newTab = Tabs.open("about:blank"); - UI.navBar.hide(); + var newTab = Tabs.open("about:blank", true); + + // Because opening a new tab happens in a different thread(?) + // calling Page.hideChrome() inline won't do anything. Instead + // we have to marshal it. A value of 0 wait time doesn't seem + // to work. Instead, we use a value of 1 which seems to be the + // minimum amount of time required. + setTimeout(function(){ + Page.hideChrome() + }, 1); var self = this; var doNextTab = function(tab){ @@ -960,8 +968,7 @@ window.Group.prototype = $.extend(new Item(), new Subscribable(), { }, 270, function(){ $(tab.container).css({opacity: 1}); newTab.focus(); - UI.tabBar.show(false); - UI.navBar.show(); + Page.showChrome() UI.navBar.urlBar.focus(); anim.remove(); // We need a timeout here so that there is a chance for the diff --git a/browser/themes/pinstripe/browser/tabcandy/tabcandy.css b/browser/themes/pinstripe/browser/tabcandy/tabcandy.css index e510c08cc49f..3915a3b3bef5 100644 --- a/browser/themes/pinstripe/browser/tabcandy/tabcandy.css +++ b/browser/themes/pinstripe/browser/tabcandy/tabcandy.css @@ -216,7 +216,7 @@ body { } .acceptsDrop{ - -moz-box-shadow: 1px 1px 3px -1px rgba(0,0,0,.5); + -moz-box-shadow: 2px 2px 10px -1px rgba(0,0,0,.6); } .titlebar{