Kaydet (Commit) 88890c2a authored tarafından Juergen Funk's avatar Juergen Funk Kaydeden (comit) Thorsten Behrens

tdf#93246: pass on cancel state in mail merge dialog

The return result was not used for the CUPS case before, leading to
un-cancelled printing / document generation in the file->print
mail merge case.

Change-Id: I470293755c6696fca6d1b97fa1dac7854b4f7107
Reviewed-on: https://gerrit.libreoffice.org/18302Reviewed-by: 's avatarThorsten Behrens <Thorsten.Behrens@CIB.de>
Tested-by: 's avatarThorsten Behrens <Thorsten.Behrens@CIB.de>
üst 90ea1221
...@@ -1311,12 +1311,13 @@ bool SwDBManager::MergeMailFiles(SwWrtShell* pSourceShell, ...@@ -1311,12 +1311,13 @@ bool SwDBManager::MergeMailFiles(SwWrtShell* pSourceShell,
pWorkView->StartPrint( aOptions, IsMergeSilent(), rMergeDescriptor.bPrintAsync ); pWorkView->StartPrint( aOptions, IsMergeSilent(), rMergeDescriptor.bPrintAsync );
SfxPrinter* pDocPrt = pWorkView->GetPrinter(); SfxPrinter* pDocPrt = pWorkView->GetPrinter();
JobSetup aJobSetup = pDocPrt ? pDocPrt->GetJobSetup() : SfxViewShell::GetJobSetup(); JobSetup aJobSetup = pDocPrt ? pDocPrt->GetJobSetup() : SfxViewShell::GetJobSetup();
Printer::PreparePrintJob( pWorkView->GetPrinterController(), aJobSetup ); bCancel = !Printer::PreparePrintJob( pWorkView->GetPrinterController(), aJobSetup );
#if ENABLE_CUPS && !defined(MACOSX) #if ENABLE_CUPS && !defined(MACOSX)
psp::PrinterInfoManager::get().startBatchPrint(); if( !bCancel )
psp::PrinterInfoManager::get().startBatchPrint();
#endif #endif
} }
if( !Printer::ExecutePrintJob( pWorkView->GetPrinterController())) if( !bCancel && !Printer::ExecutePrintJob( pWorkView->GetPrinterController()))
bCancel = true; bCancel = true;
} }
else else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment