X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8907154c1a8a6882c6797d1f16393ddfb23e7f3a..6d7b547184bfdcdf67790755deb0122050b1d728:/src/mac/classic/printdlg.cpp diff --git a/src/mac/classic/printdlg.cpp b/src/mac/classic/printdlg.cpp index f982761aa9..5928041001 100644 --- a/src/mac/classic/printdlg.cpp +++ b/src/mac/classic/printdlg.cpp @@ -1,18 +1,25 @@ ///////////////////////////////////////////////////////////////////////////// -// Name: printdlg.cpp +// Name: src/mac/classic/printdlg.cpp // Purpose: wxPrintDialog, wxPageSetupDialog // Author: Stefan Csomor // Modified by: // Created: 1998-01-01 // RCS-ID: $Id$ // Copyright: (c) Stefan Csomor -// Licence: wxWindows licence +// Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// -#include "wx/object.h" +// For compilers that support precompilation, includes "wx.h". +#include "wx/wxprec.h" + #include "wx/printdlg.h" -#include "wx/dcprint.h" -#include "wx/msgdlg.h" + +#ifndef WX_PRECOMP + #include "wx/object.h" + #include "wx/dcprint.h" + #include "wx/msgdlg.h" +#endif + #include "wx/mac/private/print.h" // Use generic page setup dialog: use your own native one if one exists. @@ -24,7 +31,7 @@ wxPrintDialog::wxPrintDialog() { m_dialogParent = NULL; m_printerDC = NULL; - m_destroyDC = TRUE; + m_destroyDC = true; } wxPrintDialog::wxPrintDialog(wxWindow *p, wxPrintDialogData* data) @@ -37,7 +44,7 @@ wxPrintDialog::wxPrintDialog(wxWindow *p, wxPrintData* data) wxPrintDialogData data2; if ( data ) data2 = *data; - + Create(p, &data2); } @@ -45,12 +52,12 @@ bool wxPrintDialog::Create(wxWindow *p, wxPrintDialogData* data) { m_dialogParent = p; m_printerDC = NULL; - m_destroyDC = TRUE; - + m_destroyDC = true; + if ( data ) m_printDialogData = *data; - - return TRUE; + + return true; } wxPrintDialog::~wxPrintDialog() @@ -67,7 +74,7 @@ int wxPrintDialog::ShowModal() int result = m_printDialogData.GetPrintData().m_nativePrintData->ShowPrintDialog() ; if ( result == wxID_OK ) m_printDialogData.ConvertFromNative() ; - + return result ; } @@ -95,11 +102,11 @@ wxDialog() bool wxPageSetupDialog::Create(wxWindow *p, wxPageSetupData *data) { m_dialogParent = p; - + if (data) m_pageSetupData = (*data); - - return TRUE; + + return true; } wxPageSetupDialog::~wxPageSetupDialog() @@ -112,7 +119,6 @@ int wxPageSetupDialog::ShowModal() int result = m_pageSetupData.GetPrintData().m_nativePrintData->ShowPageSetupDialog() ; if (result == wxID_OK ) m_pageSetupData.ConvertFromNative() ; - + return result ; } -