X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ea4daac45c2689251cc89f73e01638b15fc9cf17..0d5eaa50960aa239d910fc271f5282f24c0937cb:/src/common/uri.cpp diff --git a/src/common/uri.cpp b/src/common/uri.cpp index 0d137f5bc1..be18e65e5d 100644 --- a/src/common/uri.cpp +++ b/src/common/uri.cpp @@ -62,7 +62,7 @@ wxURI::wxURI(const wxString& uri) : m_hostType(wxURI_REGNAME), m_fields(0) Create(uri); } -wxURI::wxURI(const wxURI& uri) : m_hostType(wxURI_REGNAME), m_fields(0) +wxURI::wxURI(const wxURI& uri) : wxObject(), m_hostType(wxURI_REGNAME), m_fields(0) { Assign(uri); } @@ -79,7 +79,7 @@ wxURI::~wxURI() void wxURI::Clear() { m_scheme = m_user = m_server = m_port = m_path = - m_query = m_fragment = wxT(""); + m_query = m_fragment = wxEmptyString; m_hostType = wxURI_REGNAME; @@ -401,7 +401,7 @@ const wxChar* wxURI::ParseScheme(const wxChar* uri) } else //relative uri with relative path reference - m_scheme = wxT(""); + m_scheme = wxEmptyString; } // else //relative uri with _possible_ relative path reference @@ -450,7 +450,7 @@ const wxChar* wxURI::ParseUser(const wxChar* uri) uricopy = ++uri; } else - m_user = wxT(""); + m_user = wxEmptyString; return uricopy; } @@ -1227,7 +1227,7 @@ bool wxURI::IsDigit(const wxChar& c) // --------------------------------------------------------------------------- // -// wxURL Compatability +// wxURL Compatibility // // --------------------------------------------------------------------------- @@ -1237,6 +1237,21 @@ bool wxURI::IsDigit(const wxChar& c) #include "wx/url.h" +wxString wxURL::GetProtocolName() const +{ + return m_scheme; +} + +wxString wxURL::GetHostName() const +{ + return m_server; +} + +wxString wxURL::GetPath() const +{ + return m_path; +} + //Note that this old code really doesn't convert to a URI that well and looks //more like a dirty hack than anything else...