rename method to prevent collision with some BSD definitions of macro Free()
(detected compiling mahogany) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15982 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -93,7 +93,8 @@ protected:
|
|||||||
virtual wxClientData* DoGetItemClientObject( int n ) const;
|
virtual wxClientData* DoGetItemClientObject( int n ) const;
|
||||||
|
|
||||||
// free all memory we have (used by Clear() and dtor)
|
// free all memory we have (used by Clear() and dtor)
|
||||||
void Free();
|
// prevent collision with some BSD definitions of macro Free()
|
||||||
|
void FreeData();
|
||||||
|
|
||||||
wxArrayString m_strings;
|
wxArrayString m_strings;
|
||||||
wxChoiceDataArray m_datas ;
|
wxChoiceDataArray m_datas ;
|
||||||
|
@@ -138,7 +138,8 @@ protected:
|
|||||||
bool HasMultipleSelection() const;
|
bool HasMultipleSelection() const;
|
||||||
|
|
||||||
// free memory (common part of Clear() and dtor)
|
// free memory (common part of Clear() and dtor)
|
||||||
void Free();
|
// prevent collision with some BSD definitions of macro Free()
|
||||||
|
void FreeData();
|
||||||
|
|
||||||
int m_noItems;
|
int m_noItems;
|
||||||
int m_selected;
|
int m_selected;
|
||||||
|
@@ -33,7 +33,8 @@ public:
|
|||||||
bool Play(bool async = TRUE, bool looped = FALSE) const;
|
bool Play(bool async = TRUE, bool looped = FALSE) const;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
bool Free();
|
// prevent collision with some BSD definitions of macro Free()
|
||||||
|
bool FreeData();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void* m_sndChan;
|
void* m_sndChan;
|
||||||
|
@@ -98,7 +98,7 @@ void wxChoice::Delete(int n)
|
|||||||
|
|
||||||
void wxChoice::Clear()
|
void wxChoice::Clear()
|
||||||
{
|
{
|
||||||
Free();
|
FreeData();
|
||||||
|
|
||||||
for ( int i = 0 ; i < GetCount() ; i++ )
|
for ( int i = 0 ; i < GetCount() ; i++ )
|
||||||
{
|
{
|
||||||
@@ -109,7 +109,7 @@ void wxChoice::Clear()
|
|||||||
SetControlMaximum( (ControlHandle) m_macControl , 0 ) ;
|
SetControlMaximum( (ControlHandle) m_macControl , 0 ) ;
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxChoice::Free()
|
void wxChoice::FreeData()
|
||||||
{
|
{
|
||||||
if ( HasClientObjectData() )
|
if ( HasClientObjectData() )
|
||||||
{
|
{
|
||||||
@@ -156,7 +156,7 @@ int wxChoice::FindString(const wxString& s) const
|
|||||||
|
|
||||||
void wxChoice::SetString(int n, const wxString& s)
|
void wxChoice::SetString(int n, const wxString& s)
|
||||||
{
|
{
|
||||||
wxFAIL_MSG(wxT("not implemented"));
|
wxFAIL_MSG(wxT("wxChoice::SetString() not yet implemented"));
|
||||||
|
|
||||||
#if 0 // should do this, but no Insert() so far
|
#if 0 // should do this, but no Insert() so far
|
||||||
Delete(n);
|
Delete(n);
|
||||||
|
@@ -246,7 +246,7 @@ bool wxListBox::Create(wxWindow *parent, wxWindowID id,
|
|||||||
|
|
||||||
wxListBox::~wxListBox()
|
wxListBox::~wxListBox()
|
||||||
{
|
{
|
||||||
Free() ;
|
FreeData() ;
|
||||||
if ( m_macList )
|
if ( m_macList )
|
||||||
{
|
{
|
||||||
#if !TARGET_CARBON
|
#if !TARGET_CARBON
|
||||||
@@ -257,7 +257,7 @@ wxListBox::~wxListBox()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxListBox::Free()
|
void wxListBox::FreeData()
|
||||||
{
|
{
|
||||||
#if wxUSE_OWNER_DRAWN
|
#if wxUSE_OWNER_DRAWN
|
||||||
if ( m_windowStyle & wxLB_OWNERDRAW )
|
if ( m_windowStyle & wxLB_OWNERDRAW )
|
||||||
@@ -468,7 +468,7 @@ int wxListBox::FindString(const wxString& st) const
|
|||||||
|
|
||||||
void wxListBox::Clear()
|
void wxListBox::Clear()
|
||||||
{
|
{
|
||||||
Free();
|
FreeData();
|
||||||
m_noItems = 0;
|
m_noItems = 0;
|
||||||
m_stringArray.Empty() ;
|
m_stringArray.Empty() ;
|
||||||
m_dataArray.Empty() ;
|
m_dataArray.Empty() ;
|
||||||
|
@@ -38,7 +38,7 @@ wxWave::wxWave(const wxString& sFileName, bool isResource)
|
|||||||
|
|
||||||
wxWave::~wxWave()
|
wxWave::~wxWave()
|
||||||
{
|
{
|
||||||
Free();
|
FreeData();
|
||||||
}
|
}
|
||||||
|
|
||||||
wxWave::wxWave(int size, const wxByte* data)
|
wxWave::wxWave(int size, const wxByte* data)
|
||||||
@@ -156,7 +156,7 @@ bool wxWave::Play(bool async, bool looped) const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool wxWave::Free()
|
bool wxWave::FreeData()
|
||||||
{
|
{
|
||||||
bool ret = false;
|
bool ret = false;
|
||||||
|
|
||||||
|
@@ -98,7 +98,7 @@ void wxChoice::Delete(int n)
|
|||||||
|
|
||||||
void wxChoice::Clear()
|
void wxChoice::Clear()
|
||||||
{
|
{
|
||||||
Free();
|
FreeData();
|
||||||
|
|
||||||
for ( int i = 0 ; i < GetCount() ; i++ )
|
for ( int i = 0 ; i < GetCount() ; i++ )
|
||||||
{
|
{
|
||||||
@@ -109,7 +109,7 @@ void wxChoice::Clear()
|
|||||||
SetControlMaximum( (ControlHandle) m_macControl , 0 ) ;
|
SetControlMaximum( (ControlHandle) m_macControl , 0 ) ;
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxChoice::Free()
|
void wxChoice::FreeData()
|
||||||
{
|
{
|
||||||
if ( HasClientObjectData() )
|
if ( HasClientObjectData() )
|
||||||
{
|
{
|
||||||
@@ -156,7 +156,7 @@ int wxChoice::FindString(const wxString& s) const
|
|||||||
|
|
||||||
void wxChoice::SetString(int n, const wxString& s)
|
void wxChoice::SetString(int n, const wxString& s)
|
||||||
{
|
{
|
||||||
wxFAIL_MSG(wxT("not implemented"));
|
wxFAIL_MSG(wxT("wxChoice::SetString() not yet implemented"));
|
||||||
|
|
||||||
#if 0 // should do this, but no Insert() so far
|
#if 0 // should do this, but no Insert() so far
|
||||||
Delete(n);
|
Delete(n);
|
||||||
|
@@ -246,7 +246,7 @@ bool wxListBox::Create(wxWindow *parent, wxWindowID id,
|
|||||||
|
|
||||||
wxListBox::~wxListBox()
|
wxListBox::~wxListBox()
|
||||||
{
|
{
|
||||||
Free() ;
|
FreeData() ;
|
||||||
if ( m_macList )
|
if ( m_macList )
|
||||||
{
|
{
|
||||||
#if !TARGET_CARBON
|
#if !TARGET_CARBON
|
||||||
@@ -257,7 +257,7 @@ wxListBox::~wxListBox()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxListBox::Free()
|
void wxListBox::FreeData()
|
||||||
{
|
{
|
||||||
#if wxUSE_OWNER_DRAWN
|
#if wxUSE_OWNER_DRAWN
|
||||||
if ( m_windowStyle & wxLB_OWNERDRAW )
|
if ( m_windowStyle & wxLB_OWNERDRAW )
|
||||||
@@ -468,7 +468,7 @@ int wxListBox::FindString(const wxString& st) const
|
|||||||
|
|
||||||
void wxListBox::Clear()
|
void wxListBox::Clear()
|
||||||
{
|
{
|
||||||
Free();
|
FreeData();
|
||||||
m_noItems = 0;
|
m_noItems = 0;
|
||||||
m_stringArray.Empty() ;
|
m_stringArray.Empty() ;
|
||||||
m_dataArray.Empty() ;
|
m_dataArray.Empty() ;
|
||||||
|
@@ -38,7 +38,7 @@ wxWave::wxWave(const wxString& sFileName, bool isResource)
|
|||||||
|
|
||||||
wxWave::~wxWave()
|
wxWave::~wxWave()
|
||||||
{
|
{
|
||||||
Free();
|
FreeData();
|
||||||
}
|
}
|
||||||
|
|
||||||
wxWave::wxWave(int size, const wxByte* data)
|
wxWave::wxWave(int size, const wxByte* data)
|
||||||
@@ -156,7 +156,7 @@ bool wxWave::Play(bool async, bool looped) const
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool wxWave::Free()
|
bool wxWave::FreeData()
|
||||||
{
|
{
|
||||||
bool ret = false;
|
bool ret = false;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user