mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-02 15:15:23 +00:00
Don't dismiss the context menu so eagerly for subframe loads b=329521 r+sr=jag
This commit is contained in:
parent
5f52a767df
commit
46ee70938d
@ -261,7 +261,21 @@ nsBrowserStatusHandler.prototype =
|
||||
|
||||
onLocationChange : function(aWebProgress, aRequest, aLocation)
|
||||
{
|
||||
document.getElementById("contentAreaContextMenu").hidePopup();
|
||||
if (gContextMenu) {
|
||||
// Optimise for the common case
|
||||
if (aWebProgress.DOMWindow == content)
|
||||
gContextMenu.menu.hidePopup();
|
||||
else {
|
||||
for (var contextWindow = gContextMenu.target.ownerDocument.defaultView;
|
||||
contextWindow != contextWindow.parent;
|
||||
contextWindow = contextWindow.parent) {
|
||||
if (contextWindow == aWebProgress.DOMWindow) {
|
||||
gContextMenu.menu.hidePopup();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// XXX temporary hack for bug 104532.
|
||||
// Depends heavily on setOverLink implementation
|
||||
|
Loading…
Reference in New Issue
Block a user