]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mac/carbon/printmac.cpp
correct Stopping - go to start of movie if stopped - add in preliminary docs
[wxWidgets.git] / src / mac / carbon / printmac.cpp
index 487123bad05789946a2f38482297635d1bf4b00a..5befe63b86d1d56e78c353a701395f379eb385f2 100644 (file)
@@ -144,7 +144,7 @@ void wxMacCarbonPrintData::TransferFrom( wxPrintData* data )
     // collate cannot be set
 #if 0 // not yet tested
     if ( m_printerName.Length() > 0 )
-        PMSessionSetCurrentPrinter( (PMPrintSession) m_macPrintSession , wxMacCFStringHolder( m_printerName ) ) ;
+        PMSessionSetCurrentPrinter( (PMPrintSession) m_macPrintSession , wxMacCFStringHolder( m_printerName , wxFont::GetDefaultEncoding() ) ) ;
 #endif
     PMColorMode color ;
     PMGetColorMode(  (PMPrintSettings) m_macPrintSettings, &color ) ;
@@ -555,7 +555,7 @@ bool wxMacPrinter::Print(wxWindow *parent, wxPrintout *printout, bool prompt)
         if (dialog.ShowModal() == wxID_OK)
         {
             dc = dialog.GetPrintDC();
-            m_printDialogData = dialog.GetPrintData();
+            m_printDialogData = dialog.GetPrintDialogData();
         }
     }
     else
@@ -648,12 +648,15 @@ bool wxMacPrinter::Print(wxWindow *parent, wxPrintout *printout, bool prompt)
             }
             else
             {
-// #if !TARGET_CARBON
-                GrafPtr thePort ;
-                GetPort( &thePort ) ;
-                wxSafeYield(win,true);
-                SetPort( thePort ) ;
-// #endif                
+#if TARGET_CARBON
+                if ( UMAGetSystemVersion() >= 0x1000 )
+#endif
+                {
+                    GrafPtr thePort ;
+                    GetPort( &thePort ) ;
+                    wxSafeYield(win,true);
+                    SetPort( thePort ) ;
+                }
                 dc->StartPage();
                 keepGoing = printout->OnPrintPage(pn);
                 dc->EndPage();
@@ -696,6 +699,7 @@ wxDC* wxMacPrinter::PrintDialog(wxWindow *parent)
 
 bool wxMacPrinter::Setup(wxWindow *parent)
 {
+#if 0
     wxPrintDialog dialog(parent, & m_printDialogData);
     dialog.GetPrintDialogData().SetSetupDialog(TRUE);
     
@@ -707,6 +711,8 @@ bool wxMacPrinter::Setup(wxWindow *parent)
     }
     
     return (ret == wxID_OK);
+#endif
+    return wxID_CANCEL;
 }
 
 /*