]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/prntbase.cpp
Added licence/copyright information
[wxWidgets.git] / src / common / prntbase.cpp
index 0dd2488919cef563a492e8431fabb8f99a563ba5..b3f2e48a3ddcaca8c5e37815eec22717f3f52b3e 100644 (file)
 #include "wx/msw/printdlg.h"
 #elif defined(__WXMAC__)
 #include "wx/mac/printdlg.h"
+#include "wx/mac/private/print.h"
 #else
 #include "wx/generic/prntdlgg.h"
 #endif
 
 #ifdef __WXMSW__
-    #include "wx/msw/private.h"
-    #include <commdlg.h>
-
+    #include "wx/msw/wrapcdlg.h"
     #ifndef __WIN32__
         #include <print.h>
     #endif
@@ -134,7 +133,7 @@ wxPrintPreviewBase *wxNativePrintFactory::CreatePrintPreview( wxPrintout *previe
 #endif
 }
 
-wxPrintDialogBase *wxNativePrintFactory::CreatePrintDialog( wxWindow *parent, 
+wxPrintDialogBase *wxNativePrintFactory::CreatePrintDialog( wxWindow *parent,
                                                   wxPrintDialogData *data )
 {
 #if defined(__WXMSW__) && !defined(__WXUNIVERSAL__)
@@ -146,7 +145,7 @@ wxPrintDialogBase *wxNativePrintFactory::CreatePrintDialog( wxWindow *parent,
 #endif
 }
 
-wxPrintDialogBase *wxNativePrintFactory::CreatePrintDialog( wxWindow *parent, 
+wxPrintDialogBase *wxNativePrintFactory::CreatePrintDialog( wxWindow *parent,
                                                   wxPrintData *data )
 {
 #if defined(__WXMSW__) && !defined(__WXUNIVERSAL__)
@@ -158,7 +157,7 @@ wxPrintDialogBase *wxNativePrintFactory::CreatePrintDialog( wxWindow *parent,
 #endif
 }
 
-wxPageSetupDialogBase *wxNativePrintFactory::CreatePageSetupDialog( wxWindow *parent, 
+wxPageSetupDialogBase *wxNativePrintFactory::CreatePageSetupDialog( wxWindow *parent,
                                                   wxPageSetupDialogData *data )
 {
 #if defined(__WXMSW__) && !defined(__WXUNIVERSAL__)
@@ -183,10 +182,10 @@ bool wxNativePrintFactory::HasPrintSetupDialog()
     // the printer from the wxPrintDialog anyway.
     return true;
 #endif
-    
+
 }
 
-wxDialog *wxNativePrintFactory::CreatePrintSetupDialog( wxWindow *parent, 
+wxDialog *wxNativePrintFactory::CreatePrintSetupDialog( wxWindow *parent,
                                                         wxPrintData *data )
 {
 #if defined(__WXMSW__) && !defined(__WXUNIVERSAL__)
@@ -209,7 +208,7 @@ wxDialog *wxNativePrintFactory::CreatePrintSetupDialog( wxWindow *parent,
 bool wxNativePrintFactory::HasOwnPrintToFile()
 {
     // Only relevant for PostScript and here the
-    // setup dialog provides no "print to file" 
+    // setup dialog provides no "print to file"
     // option. In the GNOME setup dialog, the
     // setup dialog has its own print to file.
     return false;
@@ -224,7 +223,7 @@ bool wxNativePrintFactory::HasPrinterLine()
 wxString wxNativePrintFactory::CreatePrinterLine()
 {
     // Only relevant for PostScript for now
-    
+
     // We should query "lpstat -d" here
     return _("Generic PostScript");
 }
@@ -232,13 +231,13 @@ wxString wxNativePrintFactory::CreatePrinterLine()
 bool wxNativePrintFactory::HasStatusLine()
 {
     // Only relevant for PostScript for now
-    return true;    
+    return true;
 }
 
 wxString wxNativePrintFactory::CreateStatusLine()
 {
     // Only relevant for PostScript for now
-    
+
     // We should query "lpstat -r" or "lpstat -p" here
     return _("Ready");
 }
@@ -248,7 +247,7 @@ wxPrintNativeDataBase *wxNativePrintFactory::CreatePrintNativeData()
 #if defined(__WXMSW__) && !defined(__WXUNIVERSAL__)
     return new wxWindowsPrintNativeData;
 #elif defined(__WXMAC__)
-    return new wxMacPrintNativeData;
+    return new wxMacCarbonPrintData;
 #else
     return new wxPostScriptPrintNativeData;
 #endif
@@ -261,8 +260,8 @@ wxPrintNativeDataBase *wxNativePrintFactory::CreatePrintNativeData()
 IMPLEMENT_ABSTRACT_CLASS(wxPrintNativeDataBase, wxObject)
 
 wxPrintNativeDataBase::wxPrintNativeDataBase()
-{ 
-    m_ref = 1; 
+{
+    m_ref = 1;
 }
 
 //----------------------------------------------------------------------------
@@ -275,7 +274,7 @@ public:
     wxPrintFactoryModule() {}
     bool OnInit() { return true; }
     void OnExit() { wxPrintFactory::SetPrintFactory( NULL ); }
-    
+
 private:
     DECLARE_DYNAMIC_CLASS(wxPrintFactoryModule)
 };
@@ -386,7 +385,7 @@ wxPrintDialogData& wxPrinter::GetPrintDialogData() const
 IMPLEMENT_ABSTRACT_CLASS(wxPrintDialogBase, wxDialog)
 
 wxPrintDialogBase::wxPrintDialogBase(wxWindow *parent,
-                                     wxWindowID id, 
+                                     wxWindowID id,
                                      const wxString &title,
                                      const wxPoint &pos,
                                      const wxSize &size,
@@ -444,7 +443,7 @@ wxDC *wxPrintDialog::GetPrintDC()
 IMPLEMENT_ABSTRACT_CLASS(wxPageSetupDialogBase, wxDialog)
 
 wxPageSetupDialogBase::wxPageSetupDialogBase(wxWindow *parent,
-                                     wxWindowID id, 
+                                     wxWindowID id,
                                      const wxString &title,
                                      const wxPoint &pos,
                                      const wxSize &size,
@@ -1006,7 +1005,7 @@ void wxPreviewFrame::CreateControlBar()
     if (m_printPreview->GetPrintoutForPrinting())
         buttons |= wxPREVIEW_PRINT;
 
-    m_controlBar = new wxPreviewControlBar(m_printPreview, buttons, this, wxPoint(0, 0), wxSize(400, 40));
+    m_controlBar = new wxPreviewControlBar(m_printPreview, buttons, this, wxPoint(0,0), wxSize(400, 40));
     m_controlBar->CreateButtons();
 }