mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-19 16:25:38 +00:00
Bug 753845 - Fix race condition in setting/reading the selected tab. r=margaret
This commit is contained in:
parent
dd1b0e7adc
commit
e0ff9d5710
@ -127,10 +127,10 @@ public class Tabs implements GeckoEventListener {
|
||||
else
|
||||
GeckoApp.mAppContext.hideAboutHome();
|
||||
|
||||
selectedTab = tab;
|
||||
GeckoApp.mAppContext.mMainHandler.post(new Runnable() {
|
||||
public void run() {
|
||||
GeckoApp.mFormAssistPopup.hide();
|
||||
// Do we need to do this check?
|
||||
if (isSelectedTab(tab)) {
|
||||
String url = tab.getURL();
|
||||
GeckoApp.mBrowserToolbar.setTitle(tab.getDisplayTitle());
|
||||
@ -149,7 +149,7 @@ public class Tabs implements GeckoEventListener {
|
||||
|
||||
// Pass a message to Gecko to update tab state in BrowserApp
|
||||
GeckoAppShell.sendEventToGecko(GeckoEvent.createBroadcastEvent("Tab:Selected", String.valueOf(tab.getId())));
|
||||
return selectedTab = tab;
|
||||
return tab;
|
||||
}
|
||||
|
||||
public int getIndexOf(Tab tab) {
|
||||
|
Loading…
Reference in New Issue
Block a user