Bug 713008 - Tabs shouldn't flicker when hovered, r=mconley.
authorFlorian Quèze <florian@queze.net>
Tue, 10 Jan 2012 11:56:35 +0100
changeset 10382 439e89ac3f1d161362fa98431875d1f4325fc2da
parent 10381 e89709934a86b4c9e3c7421001f65fc4d2165b0b
child 10383 619bee8cb53cded516e52383b0059009bd72106b
push idunknown
push userunknown
push dateunknown
reviewersmconley
bugs713008
Bug 713008 - Tabs shouldn't flicker when hovered, r=mconley.
mail/themes/pinstripe/mail/tabmail.css
--- a/mail/themes/pinstripe/mail/tabmail.css
+++ b/mail/themes/pinstripe/mail/tabmail.css
@@ -102,16 +102,25 @@
 .tabmail-tab[selected="true"]:-moz-lwtheme {
   background: transparent;
 }
 
 .tabmail-tab:not([selected="true"]):hover {
   -moz-border-image: url(tabs/tab-hover-active.png) 4 5 3 6 fill repeat stretch;
 }
 
+/* preloading hack: the images used for tab borders need to be
+preloaded to avoid flickering the first time a non-selected tab is
+opened / hovered. */
+#tabs-toolbar::after {
+  content: '';
+  display: block;
+  background-image: url(tabs/tab-normal-active.png), url(tabs/tab-hover-active.png);
+}
+
 .tabmail-tab:-moz-lwtheme:not([selected="true"]):not(:hover) > .tab-text {
   opacity: .8;
 }
 
 .tabmail-arrowscrollbox:-moz-lwtheme > .tabs-newtab-button {
   width: auto;
   -moz-box-flex: 1;
   -moz-box-pack: start;