void wxControl::SetLabel(const wxString& title)
{
- m_label = title ;
+ m_label = wxStripMenuCodes(title) ;
if ( (ControlHandle) m_macControl )
{
wxString label ;
if( wxApp::s_macDefaultEncodingIsPC )
- label = wxMacMakeMacStringFromPC( title ) ;
+ label = wxMacMakeMacStringFromPC( m_label ) ;
else
- label = title ;
+ label = m_label ;
#if TARGET_CARBON
c2pstrcpy( (StringPtr) maclabel , label ) ;
Rect bounds ;
Str255 title ;
- MacPreControlCreate( parent , id , label , pos , size ,style, val , name , &bounds , title ) ;
+ MacPreControlCreate( parent , id , wxStripMenuCodes(label) , pos , size ,style, val , name , &bounds , title ) ;
m_macControl = ::NewControl( MAC_WXHWND(parent->MacGetRootWindow()) , &bounds , title , false , 0 , 0 , 1,
kControlGroupBoxTextTitleProc , (long) this ) ;
for (i = 0; i < n; i++)
{
- wxRadioButton *radBtn = new wxRadioButton(this, NewControlId(),choices[i],wxPoint(5,20*i+10),
+ wxRadioButton *radBtn = new wxRadioButton(this, NewControlId(), wxStripMenuCodes(choices[i]),wxPoint(5,20*i+10),
wxDefaultSize , i == 0 ? wxRB_GROUP : 0 ) ;
if ( i == 0 )
m_radioButtonCycle = radBtn ;
m_windowId = id;
m_windowStyle = style;
- m_label = label ;
+ m_label = wxStripMenuCodes(label) ;
bool ret = wxControl::Create( parent, id, pos, size, style , wxDefaultValidator , name );
SetBestSize( size ) ;
void wxControl::SetLabel(const wxString& title)
{
- m_label = title ;
+ m_label = wxStripMenuCodes(title) ;
if ( (ControlHandle) m_macControl )
{
wxString label ;
if( wxApp::s_macDefaultEncodingIsPC )
- label = wxMacMakeMacStringFromPC( title ) ;
+ label = wxMacMakeMacStringFromPC( m_label ) ;
else
- label = title ;
+ label = m_label ;
#if TARGET_CARBON
c2pstrcpy( (StringPtr) maclabel , label ) ;
Rect bounds ;
Str255 title ;
- MacPreControlCreate( parent , id , label , pos , size ,style, val , name , &bounds , title ) ;
+ MacPreControlCreate( parent , id , wxStripMenuCodes(label) , pos , size ,style, val , name , &bounds , title ) ;
m_macControl = ::NewControl( MAC_WXHWND(parent->MacGetRootWindow()) , &bounds , title , false , 0 , 0 , 1,
kControlGroupBoxTextTitleProc , (long) this ) ;
for (i = 0; i < n; i++)
{
- wxRadioButton *radBtn = new wxRadioButton(this, NewControlId(),choices[i],wxPoint(5,20*i+10),
+ wxRadioButton *radBtn = new wxRadioButton(this, NewControlId(), wxStripMenuCodes(choices[i]),wxPoint(5,20*i+10),
wxDefaultSize , i == 0 ? wxRB_GROUP : 0 ) ;
if ( i == 0 )
m_radioButtonCycle = radBtn ;
m_windowId = id;
m_windowStyle = style;
- m_label = label ;
+ m_label = wxStripMenuCodes(label) ;
bool ret = wxControl::Create( parent, id, pos, size, style , wxDefaultValidator , name );
SetBestSize( size ) ;