Compilation fix for wxCStrData handling.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45272 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Neis
2007-04-06 18:08:32 +00:00
parent 08bee49e39
commit 65f3f920ba
9 changed files with 16 additions and 16 deletions

View File

@@ -75,7 +75,7 @@ wxAcceleratorTable::wxAcceleratorTable(
m_refData = new wxAcceleratorRefData; m_refData = new wxAcceleratorRefData;
ulId = atol((char*)rResource.c_str()); ulId = atol(rResource.c_str());
hAccel = ::WinLoadAccelTable( vHabmain hAccel = ::WinLoadAccelTable( vHabmain
,NULL // resources always in .exe ,NULL // resources always in .exe
,(ULONG)ulId ,(ULONG)ulId

View File

@@ -80,7 +80,7 @@ bool wxButton::Create( wxWindow* pParent,
m_hWnd = (WXHWND)::WinCreateWindow( GetHwndOf(pParent) // Parent handle m_hWnd = (WXHWND)::WinCreateWindow( GetHwndOf(pParent) // Parent handle
,WC_BUTTON // A Button class window ,WC_BUTTON // A Button class window
,(PSZ)sLabel.c_str() // Button text ,sLabel.c_str() // Button text
,lStyle // Button style ,lStyle // Button style
,0, 0, 0, 0 // Location and size ,0, 0, 0, 0 // Location and size
,GetHwndOf(pParent) // Owner handle ,GetHwndOf(pParent) // Owner handle

View File

@@ -96,7 +96,7 @@ bool wxCheckBox::Create(wxWindow* pParent,
void wxCheckBox::SetLabel( const wxString& rsLabel ) void wxCheckBox::SetLabel( const wxString& rsLabel )
{ {
wxString sLabel=::wxPMTextToLabel(rsLabel); wxString sLabel=::wxPMTextToLabel(rsLabel);
::WinSetWindowText(GetHwnd(), (PSZ)sLabel.c_str()); ::WinSetWindowText(GetHwnd(), sLabel.c_str());
} // end of wxCheckBox::SetLabel } // end of wxCheckBox::SetLabel
wxSize wxCheckBox::DoGetBestSize() const wxSize wxCheckBox::DoGetBestSize() const

View File

@@ -134,7 +134,7 @@ int wxChoice::DoAppend(
nIndex = (int)::WinSendMsg( GetHwnd() nIndex = (int)::WinSendMsg( GetHwnd()
,LM_INSERTITEM ,LM_INSERTITEM
,(MPARAM)nIndexType ,(MPARAM)nIndexType
,(MPARAM)rsItem.c_str() ,(MPARAM)rsItem.char_str()
); );
return nIndex; return nIndex;
} // end of wxChoice::DoAppend } // end of wxChoice::DoAppend
@@ -157,7 +157,7 @@ int wxChoice::DoInsert( const wxString& rsItem, unsigned int pos )
nIndex = (int)::WinSendMsg( GetHwnd() nIndex = (int)::WinSendMsg( GetHwnd()
,LM_INSERTITEM ,LM_INSERTITEM
,(MPARAM)nIndexType ,(MPARAM)nIndexType
,(MPARAM)rsItem.c_str() ,(MPARAM)rsItem.char_str()
); );
return nIndex; return nIndex;
} // end of wxChoice::DoInsert } // end of wxChoice::DoInsert
@@ -232,7 +232,7 @@ void wxChoice::SetString(unsigned int n, const wxString& rsStr)
::WinSendMsg( GetHwnd() ::WinSendMsg( GetHwnd()
,LM_INSERTITEM ,LM_INSERTITEM
,(MPARAM)nIndexType ,(MPARAM)nIndexType
,(MPARAM)rsStr.c_str() ,(MPARAM)rsStr.char_str()
); );
if (pData) if (pData)

View File

@@ -193,7 +193,7 @@ void wxComboBox::SetValue(
if ( HasFlag(wxCB_READONLY) ) if ( HasFlag(wxCB_READONLY) )
SetStringSelection(rsValue); SetStringSelection(rsValue);
else else
::WinSetWindowText(GetHwnd(), (PSZ)rsValue.c_str()); ::WinSetWindowText(GetHwnd(), rsValue.c_str());
} // end of wxComboBox::SetValue } // end of wxComboBox::SetValue
// //
@@ -299,7 +299,7 @@ void wxComboBox::Replace( long lFrom,
// Now replace with 'value', by pasting. // Now replace with 'value', by pasting.
// //
wxSetClipboardData( wxDF_TEXT wxSetClipboardData( wxDF_TEXT
,(wxObject *)rsValue.c_str() ,rsValue.c_str()
,0 ,0
,0 ,0
); );

View File

@@ -135,8 +135,8 @@ bool wxControl::OS2CreateControl( const wxChar* zClassname,
dwStyle &= ~WS_CLIPSIBLINGS; dwStyle &= ~WS_CLIPSIBLINGS;
m_hWnd = (WXHWND)::WinCreateWindow( (HWND)GetHwndOf(pParent) // Parent window handle m_hWnd = (WXHWND)::WinCreateWindow( (HWND)GetHwndOf(pParent) // Parent window handle
,(PSZ)zClass // Window class ,zClass // Window class
,(PSZ)label.c_str() // Initial Text ,label.c_str() // Initial Text
,(ULONG)dwStyle // Style flags ,(ULONG)dwStyle // Style flags
,(LONG)0 // X pos of origin ,(LONG)0 // X pos of origin
,(LONG)0 // Y pos of origin ,(LONG)0 // Y pos of origin
@@ -244,7 +244,7 @@ void wxControl::SetLabel( const wxString& rsLabel )
label = ::wxPMTextToLabel(m_label); label = ::wxPMTextToLabel(m_label);
else else
label = m_label; label = m_label;
::WinSetWindowText(GetHwnd(), (PSZ)label.c_str()); ::WinSetWindowText(GetHwnd(), label.c_str());
} }
} // end of wxControl::SetLabel } // end of wxControl::SetLabel

View File

@@ -1753,7 +1753,7 @@ void wxDC::DrawAnyText( const wxString& rsText,
vPtlStart.y = vY; vPtlStart.y = vY;
} }
PCH pzStr = (PCH)rsText.c_str(); PCH pzStr = rsText.char_str();
::GpiMove(m_hPS, &vPtlStart); ::GpiMove(m_hPS, &vPtlStart);
lHits = ::GpiCharString( m_hPS lHits = ::GpiCharString( m_hPS
@@ -2178,7 +2178,7 @@ void wxDC::DoGetTextExtent(
// //
bRc = ::GpiQueryTextBox( m_hPS bRc = ::GpiQueryTextBox( m_hPS
,l ,l
,(PCH)rsString.c_str() ,rsString.char_str()
,TXTBOX_COUNT // return maximum information ,TXTBOX_COUNT // return maximum information
,avPoint // array of coordinates points ,avPoint // array of coordinates points
); );

View File

@@ -41,8 +41,8 @@ wxPrinterDC::wxPrinterDC( const wxString& rsDriverName,
bool bInteractive, bool bInteractive,
int nOrientation ) int nOrientation )
{ {
DEVOPENSTRUC vDevOpen = { (char*)rsDeviceName.c_str() DEVOPENSTRUC vDevOpen = { rsDeviceName.char_str()
,(char*)rsDriverName.c_str() ,rsDriverName.char_str()
,NULL ,NULL
,NULL ,NULL
,NULL ,NULL

View File

@@ -222,7 +222,7 @@ bool wxDialog::Show( bool bShow )
wxString title = GetTitle(); wxString title = GetTitle();
if (!title.empty()) if (!title.empty())
::WinSetWindowText((HWND)GetHwnd(), (PSZ)title.c_str()); ::WinSetWindowText((HWND)GetHwnd(), title.c_str());
if ( bShow ) if ( bShow )
{ {