]> git.saurik.com Git - wxWidgets.git/commitdiff
Compilation fix for wxCStrData handling.
authorStefan Neis <Stefan.Neis@t-online.de>
Fri, 6 Apr 2007 18:08:32 +0000 (18:08 +0000)
committerStefan Neis <Stefan.Neis@t-online.de>
Fri, 6 Apr 2007 18:08:32 +0000 (18:08 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45272 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/os2/accel.cpp
src/os2/button.cpp
src/os2/checkbox.cpp
src/os2/choice.cpp
src/os2/combobox.cpp
src/os2/control.cpp
src/os2/dc.cpp
src/os2/dcprint.cpp
src/os2/dialog.cpp

index 3dc254182f641b23d25ac4815d8ef3dae2c23b91..fc5f2a319b4c8ad5be8c07b36c424d7543646be6 100644 (file)
@@ -75,7 +75,7 @@ wxAcceleratorTable::wxAcceleratorTable(
 
     m_refData = new wxAcceleratorRefData;
 
-    ulId = atol((char*)rResource.c_str());
+    ulId = atol(rResource.c_str());
     hAccel = ::WinLoadAccelTable( vHabmain
                                  ,NULL // resources always in .exe
                                  ,(ULONG)ulId
index 838cc7413ba7e7b7a306ea91c15c5a71773ed931..746e0300c4152d61e25846103e94e3ae6c30483c 100644 (file)
@@ -80,7 +80,7 @@ bool wxButton::Create( wxWindow*          pParent,
 
     m_hWnd = (WXHWND)::WinCreateWindow( GetHwndOf(pParent)   // Parent handle
                                        ,WC_BUTTON            // A Button class window
-                                       ,(PSZ)sLabel.c_str()  // Button text
+                                       ,sLabel.c_str()  // Button text
                                        ,lStyle               // Button style
                                        ,0, 0, 0, 0           // Location and size
                                        ,GetHwndOf(pParent)   // Owner handle
index 84d93fc94b39162d987fd5ca6a03be44121db7ec..2925980a9fd3b0c243a4f8871dd27a086076c01a 100644 (file)
@@ -96,7 +96,7 @@ bool wxCheckBox::Create(wxWindow* pParent,
 void wxCheckBox::SetLabel( const wxString& rsLabel )
 {
     wxString  sLabel=::wxPMTextToLabel(rsLabel);
-    ::WinSetWindowText(GetHwnd(), (PSZ)sLabel.c_str());
+    ::WinSetWindowText(GetHwnd(), sLabel.c_str());
 } // end of wxCheckBox::SetLabel
 
 wxSize wxCheckBox::DoGetBestSize() const
index 1e62c4f6c000afe2bfa38bffa4e8e823a38b98a7..0b769aceb8840a7e98a161a746a83af9af6160b2 100644 (file)
@@ -134,7 +134,7 @@ int wxChoice::DoAppend(
     nIndex = (int)::WinSendMsg( GetHwnd()
                                ,LM_INSERTITEM
                                ,(MPARAM)nIndexType
-                               ,(MPARAM)rsItem.c_str()
+                               ,(MPARAM)rsItem.char_str()
                               );
     return nIndex;
 } // end of wxChoice::DoAppend
@@ -157,7 +157,7 @@ int wxChoice::DoInsert( const wxString& rsItem, unsigned int pos )
     nIndex = (int)::WinSendMsg( GetHwnd()
                                ,LM_INSERTITEM
                                ,(MPARAM)nIndexType
-                               ,(MPARAM)rsItem.c_str()
+                               ,(MPARAM)rsItem.char_str()
                               );
     return nIndex;
 } // end of wxChoice::DoInsert
@@ -232,7 +232,7 @@ void wxChoice::SetString(unsigned int n, const wxString& rsStr)
     ::WinSendMsg( GetHwnd()
                  ,LM_INSERTITEM
                  ,(MPARAM)nIndexType
-                 ,(MPARAM)rsStr.c_str()
+                 ,(MPARAM)rsStr.char_str()
                 );
 
     if (pData)
index 2c28d28b70c4bb1d3cda431c9152129dd9d4426c..d3ff05da08fab752c49dda6e1cea85648335d8b3 100644 (file)
@@ -193,7 +193,7 @@ void wxComboBox::SetValue(
     if ( HasFlag(wxCB_READONLY) )
         SetStringSelection(rsValue);
     else
-        ::WinSetWindowText(GetHwnd(), (PSZ)rsValue.c_str());
+        ::WinSetWindowText(GetHwnd(), rsValue.c_str());
 } // end of wxComboBox::SetValue
 
 //
@@ -299,7 +299,7 @@ void wxComboBox::Replace( long lFrom,
     // Now replace with 'value', by pasting.
     //
     wxSetClipboardData( wxDF_TEXT
-                       ,(wxObject *)rsValue.c_str()
+                       ,rsValue.c_str()
                        ,0
                        ,0
                       );
index 09bf756b6f4e842414dd245a795b3488e1075e38..63650453c83fcb8ac3223a65a0bbb786199b900a 100644 (file)
@@ -135,8 +135,8 @@ bool wxControl::OS2CreateControl( const wxChar*   zClassname,
     dwStyle &= ~WS_CLIPSIBLINGS;
 
     m_hWnd = (WXHWND)::WinCreateWindow( (HWND)GetHwndOf(pParent) // Parent window handle
-                                       ,(PSZ)zClass              // Window class
-                                       ,(PSZ)label.c_str()       // Initial Text
+                                       ,zClass              // Window class
+                                       ,label.c_str()       // Initial Text
                                        ,(ULONG)dwStyle           // Style flags
                                        ,(LONG)0                  // X pos of origin
                                        ,(LONG)0                  // Y pos of origin
@@ -244,7 +244,7 @@ void wxControl::SetLabel( const wxString& rsLabel )
             label = ::wxPMTextToLabel(m_label);
         else
             label = m_label;
-        ::WinSetWindowText(GetHwnd(), (PSZ)label.c_str());
+        ::WinSetWindowText(GetHwnd(), label.c_str());
     }
 } // end of wxControl::SetLabel
 
index efce57c91e5ff0cad98176f1fa224367cc7c1faf..1a65b1804c4a7c97856f9d60b686a0df58d59ec6 100644 (file)
@@ -1753,7 +1753,7 @@ void wxDC::DrawAnyText( const wxString& rsText,
             vPtlStart.y = vY;
     }
 
-    PCH pzStr = (PCH)rsText.c_str();
+    PCH pzStr = rsText.char_str();
 
     ::GpiMove(m_hPS, &vPtlStart);
     lHits = ::GpiCharString( m_hPS
@@ -2178,7 +2178,7 @@ void wxDC::DoGetTextExtent(
     //
     bRc = ::GpiQueryTextBox( m_hPS
                             ,l
-                            ,(PCH)rsString.c_str()
+                            ,rsString.char_str()
                             ,TXTBOX_COUNT // return maximum information
                             ,avPoint      // array of coordinates points
                            );
index 30ba0d7c3a2782b32ab8e5b1d58a92d51ca95232..807340d397979131b225e6c6bc5c602ec238322e 100644 (file)
@@ -41,8 +41,8 @@ wxPrinterDC::wxPrinterDC( const wxString& rsDriverName,
                           bool bInteractive,
                           int nOrientation )
 {
-    DEVOPENSTRUC    vDevOpen = { (char*)rsDeviceName.c_str()
-                                ,(char*)rsDriverName.c_str()
+    DEVOPENSTRUC    vDevOpen = { rsDeviceName.char_str()
+                                ,rsDriverName.char_str()
                                 ,NULL
                                 ,NULL
                                 ,NULL
index 12d98447d1b63c693f15e9182a0eb1203be18784..e17a1414d8736fb0fd4276f838db47305102df69 100644 (file)
@@ -222,7 +222,7 @@ bool wxDialog::Show( bool bShow )
 
     wxString title = GetTitle();
     if (!title.empty())
-        ::WinSetWindowText((HWND)GetHwnd(), (PSZ)title.c_str());
+        ::WinSetWindowText((HWND)GetHwnd(), title.c_str());
 
     if ( bShow )
     {