[Libreoffice-commits] core.git: vcl/source
Oliver-Rainer Wittmann
orw at apache.org
Fri May 24 12:45:40 PDT 2013
vcl/source/gdi/print3.cxx | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
New commits:
commit 3bcbc800a5598854be473a7397eac384e0d8a07e
Author: Oliver-Rainer Wittmann <orw at apache.org>
Date: Fri Apr 19 10:41:08 2013 +0000
Resolves: #i120529# abort print controller job, if no pages will be printed
(cherry picked from commit aad8d0b80c56b956ce674e713d4d09a077e20f68)
Change-Id: I7c341961370ce12de1aeb8f0caed18f2dc496390
diff --git a/vcl/source/gdi/print3.cxx b/vcl/source/gdi/print3.cxx
index 7ea71cc..a3f976b 100644
--- a/vcl/source/gdi/print3.cxx
+++ b/vcl/source/gdi/print3.cxx
@@ -658,7 +658,13 @@ bool Printer::StartJob( const OUString& i_rJobName, boost::shared_ptr<vcl::Print
{
mbJobActive = sal_True;
i_pController->createProgressDialog();
- int nPages = i_pController->getFilteredPageCount();
+ const int nPages = i_pController->getFilteredPageCount();
+ // abort job, if no pages will be printed.
+ if ( nPages == 0 )
+ {
+ i_pController->abortJob();
+ bAborted = true;
+ }
for( int nOuterIteration = 0; nOuterIteration < nOuterRepeatCount && ! bAborted; nOuterIteration++ )
{
for( int nPage = 0; nPage < nPages && ! bAborted; nPage++ )
More information about the Libreoffice-commits
mailing list