mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 844473: Honor mozdisallowselectionprint and moznomarginboxes in print preview as well as print. r=roc
This commit is contained in:
parent
55dbf3e3b5
commit
e8d1507857
@ -3701,6 +3701,13 @@ nsDocumentViewer::PrintPreview(nsIPrintSettings* aPrintSettings,
|
||||
if (mPrintEngine->HasPrintCallbackCanvas()) {
|
||||
mBeforeAndAfterPrint = beforeAndAfterPrint;
|
||||
}
|
||||
dom::Element* root = mDocument->GetRootElement();
|
||||
if (root && root->HasAttr(kNameSpaceID_None, nsGkAtoms::mozdisallowselectionprint)) {
|
||||
mPrintEngine->SetDisallowSelectionPrint(true);
|
||||
}
|
||||
if (root && root->HasAttr(kNameSpaceID_None, nsGkAtoms::moznomarginboxes)) {
|
||||
mPrintEngine->SetNoMarginBoxes(true);
|
||||
}
|
||||
rv = mPrintEngine->PrintPreview(aPrintSettings, aChildDOMWin, aWebProgressListener);
|
||||
mPrintPreviewZoomed = false;
|
||||
if (NS_FAILED(rv)) {
|
||||
|
Loading…
Reference in New Issue
Block a user