tdf#86671: Cancel printing if query is cancelled

cancelling query for mail merge vs. normal printing
should cancel the request

Change-Id: I157778efc9e5db42646fb3ff238a5b6f4c8dccca
Reviewed-on: https://gerrit.libreoffice.org/18339
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
This commit is contained in:
Oliver Specht
2015-09-04 14:40:18 +02:00
committed by Thorsten Behrens
parent 457ccbe1d3
commit 75f890a785

View File

@@ -204,12 +204,15 @@ void SwView::ExecutePrint(SfxRequest& rReq)
ScopedVclPtrInstance<MessageDialog> aBox(&GetEditWin(), "PrintMergeDialog",
"modules/swriter/ui/printmergedialog.ui");
short nRet = aBox->Execute();
if(RET_YES == nRet)
if(RET_NO != nRet)
{
SfxBoolItem aBool(FN_QRY_MERGE, true);
GetViewFrame()->GetDispatcher()->Execute(
FN_QRY_MERGE, SfxCallMode::ASYNCHRON, &aBool, 0L);
rReq.Ignore();
if(RET_YES == nRet)
{
SfxBoolItem aBool(FN_QRY_MERGE, true);
GetViewFrame()->GetDispatcher()->Execute(
FN_QRY_MERGE, SfxCallMode::ASYNCHRON, &aBool, 0L);
rReq.Ignore();
}
return;
}
}