зеркало из https://github.com/mozilla/gecko-dev.git
bug 22342, r=danm, back out ben's hack to try to load URL in current window if empty otherwise load in a new window, now always load using openTopWin()
This commit is contained in:
Родитель
47d6625a64
Коммит
9c925e6e4d
|
@ -71,7 +71,6 @@ catch (ex)
|
||||||
|
|
||||||
// focused frame URL
|
// focused frame URL
|
||||||
var gFocusedURL = null;
|
var gFocusedURL = null;
|
||||||
var gNavigated = -1;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Save the document at a given location to disk
|
* Save the document at a given location to disk
|
||||||
|
@ -99,7 +98,6 @@ function savePage( url )
|
||||||
**/
|
**/
|
||||||
function getContentAreaFrameCount()
|
function getContentAreaFrameCount()
|
||||||
{
|
{
|
||||||
gNavigated++;
|
|
||||||
var saveFrameItem = document.getElementById("savepage");
|
var saveFrameItem = document.getElementById("savepage");
|
||||||
if (!window._content.frames.length ||
|
if (!window._content.frames.length ||
|
||||||
!isDocumentFrame(document.commandDispatcher.focusedWindow))
|
!isDocumentFrame(document.commandDispatcher.focusedWindow))
|
||||||
|
@ -929,8 +927,7 @@ function RevealSearchPanel()
|
||||||
fp.appendFilters(nsIFilePicker.filterHTML | nsIFilePicker.filterText |
|
fp.appendFilters(nsIFilePicker.filterHTML | nsIFilePicker.filterText |
|
||||||
nsIFilePicker.filterAll | nsIFilePicker.filterImages | nsIFilePicker.filterXML);
|
nsIFilePicker.filterAll | nsIFilePicker.filterImages | nsIFilePicker.filterXML);
|
||||||
if (fp.show() == nsIFilePicker.returnOK) {
|
if (fp.show() == nsIFilePicker.returnOK) {
|
||||||
var fn = !gNavigated ? openTopWin : openNewWindowWith;
|
openTopWin(fp.fileURL.spec);
|
||||||
fn(fp.fileURL.spec);
|
|
||||||
}
|
}
|
||||||
} catch (ex) { }
|
} catch (ex) { }
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче