Detect new tabs opened from content scripts correctly (#517, #510)

This commit is contained in:
YUKI Hiroshi 2013-07-02 19:47:41 +09:00
parent 9999d7f135
commit c03ad9eaff

View File

@ -1138,7 +1138,7 @@ TreeStyleTabWindow.prototype = {
onBeforeBrowserAccessOpenURI : function TSTWindow_onBeforeBrowserAccessOpenURI(aOpener, aWhere)
{
if (aOpener &&
aOpener.top == this.browser.contentWindow &&
this.getTabFromFrame(aOpener.top) &&
aWhere == Ci.nsIBrowserDOMWindow.OPEN_NEWTAB)
this.handleNewTabFromCurrent(aOpener);
},