browser/base/content/test/general/browser_bug655584.js

Thu, 15 Jan 2015 21:03:48 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 15 Jan 2015 21:03:48 +0100
branch
TOR_BUG_9701
changeset 11
deefc01c0e14
permissions
-rw-r--r--

Integrate friendly tips from Tor colleagues to make (or not) 4.5 alpha 3;
This includes removal of overloaded (but unused) methods, and addition of
a overlooked call to DataStruct::SetData(nsISupports, uint32_t, bool.)

     1 /* Any copyright is dedicated to the Public Domain.
     2  * http://creativecommons.org/publicdomain/zero/1.0/
     3  */
     5 // Bug 655584 - awesomebar suggestions don't update after tab is closed
     7 function test() {
     8   var tab1 = gBrowser.addTab();
     9   var tab2 = gBrowser.addTab();
    11   // When urlbar in a new tab is focused, and a tab switch occurs,
    12   // the urlbar popup should be closed
    13   gBrowser.selectedTab = tab2;
    14   gURLBar.focus(); // focus the urlbar in the tab we will switch to
    15   gBrowser.selectedTab = tab1;
    16   gURLBar.openPopup();
    17   gBrowser.selectedTab = tab2;
    18   ok(!gURLBar.popupOpen, "urlbar focused in tab to switch to, close popup");
    20   // cleanup
    21   gBrowser.removeCurrentTab();
    22   gBrowser.removeCurrentTab();
    23 }

mercurial