]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/printwin.cpp
return if abort dialog couldn't be created (part of patch 1160117)
[wxWidgets.git] / src / msw / printwin.cpp
index 727d956f2c52ec16a25845db117626b7979bd55f..cd496d3291d7627229183ab42abadcb3336253c8 100644 (file)
@@ -210,6 +210,7 @@ bool wxWindowsPrinter::Print(wxWindow *parent, wxPrintout *printout, bool prompt
         sm_lastError = wxPRINTER_ERROR;
 
         delete dc;
+        return false;
     }
     sm_abortWindow = win;
     sm_abortWindow->Show();
@@ -281,7 +282,7 @@ bool wxWindowsPrinter::Print(wxWindow *parent, wxPrintout *printout, bool prompt
 
     delete dc;
 
-    return (sm_lastError == wxPRINTER_NO_ERROR);
+    return sm_lastError == wxPRINTER_NO_ERROR;
 }
 
 wxDC* wxWindowsPrinter::PrintDialog(wxWindow *parent)
@@ -428,9 +429,9 @@ LONG APIENTRY _EXPORT wxAbortProc(HDC WXUNUSED(hPr), int WXUNUSED(Code))
             DispatchMessage(&msg);
         }
 
-        /* bAbort is TRUE (return is FALSE) if the user has aborted */
+    /* bAbort is TRUE (return is FALSE) if the user has aborted */
 
-        return (!wxPrinterBase::sm_abortIt);
+    return !wxPrinterBase::sm_abortIt;
 }
 
 #endif