mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 22:01:30 +00:00
Forgot to initialize the arg to false, and th js code needs to finsih PP in the catch if an error is passed back.
Bug 157129 r=carlen sr=waterson a=asa
This commit is contained in:
parent
b4cbaefe10
commit
2c95359558
@ -76,7 +76,6 @@ NS_IMETHODIMP nsPrintProgress::OpenProgressDialog(nsIDOMWindowInternal *parent,
|
||||
nsIObserver *openDialogObserver,
|
||||
PRBool *notifyOnOpen)
|
||||
{
|
||||
*notifyOnOpen = PR_TRUE;
|
||||
m_observer = openDialogObserver;
|
||||
|
||||
nsresult rv = NS_ERROR_FAILURE;
|
||||
@ -111,6 +110,9 @@ NS_IMETHODIMP nsPrintProgress::OpenProgressDialog(nsIDOMWindowInternal *parent,
|
||||
NS_LITERAL_STRING("_blank"),
|
||||
NS_LITERAL_STRING("chrome,titlebar,dependent,centerscreen"),
|
||||
array, getter_AddRefs(newWindow));
|
||||
if (NS_SUCCEEDED(rv)) {
|
||||
*notifyOnOpen = PR_TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
return rv;
|
||||
|
@ -278,6 +278,8 @@ nsPrintingPromptService::ShowProgress(nsIDOMWindow* parent,
|
||||
NS_ENSURE_ARG(printProgressParams);
|
||||
NS_ENSURE_ARG(notifyOnOpen);
|
||||
|
||||
*notifyOnOpen = PR_FALSE;
|
||||
|
||||
// If running on OS X, the printing manager displays a nice progress dialog
|
||||
// so we don't need to do this. Keeping this code here in order to support
|
||||
// running TARGET_CARBON builds on OS 9.
|
||||
|
@ -267,7 +267,9 @@ function BrowserPrintPreview()
|
||||
if (!notifyOnOpen.value.valueOf() || gWebProgress.value == null) {
|
||||
FinishPrintPreview();
|
||||
}
|
||||
} catch (e) {}
|
||||
} catch (e) {
|
||||
FinishPrintPreview();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user