X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/bba0174ac72712c2b9c38a317bf8d24059b105f4..8a3f03ffce938a24ecc154b614072457b3900ed0:/src/common/fileconf.cpp diff --git a/src/common/fileconf.cpp b/src/common/fileconf.cpp index d5626c7709..e3b61cf806 100644 --- a/src/common/fileconf.cpp +++ b/src/common/fileconf.cpp @@ -137,7 +137,7 @@ private: wxFileConfigLineList *m_pNext, // next node *m_pPrev; // previous one - DECLARE_NO_COPY_CLASS(wxFileConfigLineList) + wxDECLARE_NO_COPY_CLASS(wxFileConfigLineList); }; // ---------------------------------------------------------------------------- @@ -178,7 +178,7 @@ public: void SetValue(const wxString& strValue, bool bUser = true); void SetLine(wxFileConfigLineList *pLine); - DECLARE_NO_COPY_CLASS(wxFileConfigEntry) + wxDECLARE_NO_COPY_CLASS(wxFileConfigEntry); }; // ---------------------------------------------------------------------------- @@ -250,7 +250,7 @@ public: void SetLastGroup(wxFileConfigGroup *pGroup) { m_pLastGroup = pGroup; } - DECLARE_NO_COPY_CLASS(wxFileConfigGroup) + wxDECLARE_NO_COPY_CLASS(wxFileConfigGroup); }; // ============================================================================ @@ -471,7 +471,7 @@ wxFileConfig::wxFileConfig(wxInputStream &inStream, const wxMBConv& conv) } #else // !wxUSE_UNICODE // no need for conversion - cbuf = wxCharBuffer::CreateNonOwned((char *)buf.GetData()); + cbuf = wxCharBuffer::CreateNonOwned((char *)buf.GetData(), buf.GetDataLen()); #endif // wxUSE_UNICODE/!wxUSE_UNICODE @@ -827,7 +827,7 @@ bool wxFileConfig::HasGroup(const wxString& strName) const const wxString pathOld = GetPath(); - wxFileConfig *self = wx_const_cast(wxFileConfig *, this); + wxFileConfig *self = const_cast(this); const bool rc = self->DoSetPath(strName, false /* don't create missing components */); @@ -850,7 +850,7 @@ bool wxFileConfig::HasEntry(const wxString& entry) const // change to the path of the entry if necessary and remember the old path // to restore it later wxString pathOld; - wxFileConfig * const self = wx_const_cast(wxFileConfig *, this); + wxFileConfig * const self = const_cast(this); if ( !path.empty() ) { pathOld = GetPath(); @@ -1035,7 +1035,7 @@ bool wxFileConfig::Flush(bool /* bCurrentOnly */) ResetDirty(); -#if defined(__WXMAC__) +#if defined( __WXOSX_MAC__ ) && wxOSX_USE_CARBON m_fnLocalFile.MacSetTypeAndCreator('TEXT', 'ttxt'); #endif // __WXMAC__ @@ -1678,9 +1678,9 @@ bool wxFileConfigGroup::DeleteSubgroup(wxFileConfigGroup *pGroup) wxLogTrace( FILECONF_TRACE_MASK, _T(" (m_pLine) = prev: %p, this %p, next %p"), - m_pLine ? wx_static_cast(void*, m_pLine->Prev()) : 0, - wx_static_cast(void*, m_pLine), - m_pLine ? wx_static_cast(void*, m_pLine->Next()) : 0 ); + m_pLine ? static_cast(m_pLine->Prev()) : 0, + static_cast(m_pLine), + m_pLine ? static_cast(m_pLine->Next()) : 0 ); wxLogTrace( FILECONF_TRACE_MASK, _T(" text: '%s'"), m_pLine ? (const wxChar*)m_pLine->Text().c_str()