Bug 762717: selectTab() should be called after closeTab(). [r=margaret]

--HG--
extra : rebase_source : 71c641402c2a7dc0716bd1f7029395e6e38b4297
This commit is contained in:
Sriram Ramasubramanian 2012-06-14 12:12:09 -07:00
Родитель 80521174e0
Коммит 3f8fd2dd77
1 изменённых файлов: 3 добавлений и 2 удалений

Просмотреть файл

@ -157,8 +157,6 @@ public class Tabs implements GeckoEventListener {
if (tab == null || nextTab == null)
return;
selectTab(nextTab.getId());
int tabId = tab.getId();
removeTab(tabId);
tab.onDestroy();
@ -171,6 +169,9 @@ public class Tabs implements GeckoEventListener {
// Pass a message to Gecko to update tab state in BrowserApp
GeckoAppShell.sendEventToGecko(GeckoEvent.createBroadcastEvent("Tab:Closed", String.valueOf(tabId)));
// Next tab selection should happen after closing the tab.
selectTab(nextTab.getId());
}
/** Return the tab that will be selected by default after this one is closed */