diff --git a/src/common/filesys.cpp b/src/common/filesys.cpp index 149df69350..82bb76e86c 100644 --- a/src/common/filesys.cpp +++ b/src/common/filesys.cpp @@ -124,7 +124,7 @@ wxString wxFileSystemHandler::GetMimeTypeFromExt(const wxString& location) wxFileType *ft = wxTheMimeTypesManager->GetFileTypeFromExtension(ext); if ( !ft || !ft -> GetMimeType(&mime) ) { - mime = wxEmptyString; + mime.clear(); } delete ft; @@ -427,7 +427,7 @@ void wxFileSystem::ChangePathTo(const wxString& location, bool is_dir) } } if (i == (int) m_Path.length()) - m_Path = wxEmptyString; + m_Path.clear(); } else { @@ -480,7 +480,7 @@ wxFSFile* wxFileSystem::OpenFile(const wxString& location, int flags) } if (meta != 0) break; } - m_LastName = wxEmptyString; + m_LastName.clear(); // try relative paths first : if (meta != wxT(':')) diff --git a/src/common/intl.cpp b/src/common/intl.cpp index a2e6a68a03..df4c840a84 100644 --- a/src/common/intl.cpp +++ b/src/common/intl.cpp @@ -535,7 +535,7 @@ bool wxLocale::Init(int language, int flags) ret = false; #elif defined(__WXMAC__) if (lang == wxLANGUAGE_DEFAULT) - locale = wxEmptyString; + locale.clear(); else locale = info->CanonicalName; diff --git a/src/common/tarstrm.cpp b/src/common/tarstrm.cpp index 944835e927..d909e7fcb2 100644 --- a/src/common/tarstrm.cpp +++ b/src/common/tarstrm.cpp @@ -596,7 +596,7 @@ wxString wxTarEntry::GetInternalName(const wxString& name, while (!internal.empty() && internal.compare(0, 2, wxT("./")) == 0) internal.erase(0, 2); if (internal == wxT(".") || internal == wxT("..")) - internal = wxEmptyString; + internal.clear(); return internal; } diff --git a/src/common/uri.cpp b/src/common/uri.cpp index ff01b850f5..959f4ea2c9 100644 --- a/src/common/uri.cpp +++ b/src/common/uri.cpp @@ -67,13 +67,13 @@ bool wxURI::Create(const wxString& uri) void wxURI::Clear() { - m_scheme = - m_userinfo = - m_server = - m_port = - m_path = - m_query = - m_fragment = wxEmptyString; + m_scheme.clear(); + m_userinfo.clear(); + m_server.clear(); + m_port.clear(); + m_path.clear(); + m_query.clear(); + m_fragment.clear(); m_hostType = wxURI_REGNAME; diff --git a/src/common/variant.cpp b/src/common/variant.cpp index a8693207dd..e01d1e84f7 100644 --- a/src/common/variant.cpp +++ b/src/common/variant.cpp @@ -72,7 +72,7 @@ void wxVariant::MakeNull() void wxVariant::Clear() { - m_name = wxEmptyString; + m_name.clear(); } wxVariant::wxVariant(const wxVariant& variant) @@ -2071,7 +2071,7 @@ bool wxVariantDataList::Write(wxSTD ostream& str) const bool wxVariantDataList::Write(wxString& str) const { - str = wxEmptyString; + str.clear(); wxVariantList::compatibility_iterator node = m_value.GetFirst(); while (node) { diff --git a/src/common/xtixml.cpp b/src/common/xtixml.cpp index 4a37afe6b6..d30af28a3f 100644 --- a/src/common/xtixml.cpp +++ b/src/common/xtixml.cpp @@ -363,7 +363,7 @@ int wxObjectXmlReader::ReadComponent(wxXmlNode *node, wxObjectReaderCallback *ca { if ( propertyNames[j] == paramName ) { - propertyNames[j] = wxEmptyString; + propertyNames[j].clear(); break; } } diff --git a/src/common/zipstrm.cpp b/src/common/zipstrm.cpp index aa68db4bb4..ab6bef75d6 100644 --- a/src/common/zipstrm.cpp +++ b/src/common/zipstrm.cpp @@ -901,7 +901,7 @@ wxString wxZipEntry::GetInternalName(const wxString& name, (internal[0] == wxS('.') && IsDOSPathSep(internal[1]))) internal.erase(0, 2); if (internal == wxT(".") || internal == wxT("..")) - internal = wxEmptyString; + internal.clear(); return internal; } diff --git a/src/html/styleparams.cpp b/src/html/styleparams.cpp index 51ed812dfe..929eb98d43 100644 --- a/src/html/styleparams.cpp +++ b/src/html/styleparams.cpp @@ -42,7 +42,7 @@ wxHtmlStyleParams::wxHtmlStyleParams(const wxHtmlTag& tag) else { // Syntax problem change to blank string - wd = ""; + wd.clear(); } } diff --git a/src/osx/fswatcher_fsevents.cpp b/src/osx/fswatcher_fsevents.cpp index 849beb97ec..b90f96febf 100644 --- a/src/osx/fswatcher_fsevents.cpp +++ b/src/osx/fswatcher_fsevents.cpp @@ -86,7 +86,7 @@ private: static int wxFSEventsToWatcherFlags(FSEventStreamEventFlags flags, wxFSWWarningType& warning, wxString& msg) { - msg = ""; + msg.clear(); warning = wxFSW_WARNING_NONE; // see https://developer.apple.com/library/mac/documentation/Darwin/Reference/FSEvents_Ref/index.html