]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/printdlg.cpp
Fixes for wxPopupTransientWindow for wxMSW. Includes Patch #1181190,
[wxWidgets.git] / src / msw / printdlg.cpp
index abe7e64ad4927453650ce4c904af8848b8443b5c..02892c45100bbaeae8049e8391bbf4bacb1abdfd 100644 (file)
@@ -44,9 +44,7 @@
 
 #include <stdlib.h>
 
 
 #include <stdlib.h>
 
-#include "wx/msw/private.h"
-
-#include <commdlg.h>
+#include "wx/msw/wrapcdlg.h"
 
 #ifndef __WIN32__
     #include <print.h>
 
 #ifndef __WIN32__
     #include <print.h>
@@ -302,7 +300,7 @@ bool wxWindowsPrintNativeData::TransferTo( wxPrintData &data )
             wxString printerName = (LPTSTR)lpDevNames + lpDevNames->wDeviceOffset;
 
             // Not sure if we should check for this mismatch
             wxString printerName = (LPTSTR)lpDevNames + lpDevNames->wDeviceOffset;
 
             // Not sure if we should check for this mismatch
-//            wxASSERT_MSG( (m_printerName == "" || (devName == m_printerName)), "Printer name obtained from DEVMODE and DEVNAMES were different!");
+//            wxASSERT_MSG( (m_printerName.empty() || (devName == m_printerName)), "Printer name obtained from DEVMODE and DEVNAMES were different!");
 
             if (!printerName.empty())
                 data.SetPrinterName( printerName );
 
             if (!printerName.empty())
                 data.SetPrinterName( printerName );
@@ -474,11 +472,11 @@ bool wxWindowsPrintNativeData::TransferFrom( const wxPrintData &data )
         }
         devMode->dmPrintQuality = quality;
         devMode->dmFields |= DM_PRINTQUALITY;
         }
         devMode->dmPrintQuality = quality;
         devMode->dmFields |= DM_PRINTQUALITY;
-        
+
         if (data.GetPrivDataLen() > 0)
         {
             memcpy( (char *)devMode+devMode->dmSize, data.GetPrivData(), data.GetPrivDataLen() );
         if (data.GetPrivDataLen() > 0)
         {
             memcpy( (char *)devMode+devMode->dmSize, data.GetPrivData(), data.GetPrivDataLen() );
-            devMode->dmDriverExtra = data.GetPrivDataLen();
+            devMode->dmDriverExtra = (WXWORD)data.GetPrivDataLen();
         }
 
         if (data.GetBin() != wxPRINTBIN_DEFAULT)
         }
 
         if (data.GetBin() != wxPRINTBIN_DEFAULT)