git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@35138
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
IMPLEMENT_PROTOCOL(wxFileProto, wxT("file"), NULL, false)
wxFileProto::wxFileProto()
IMPLEMENT_PROTOCOL(wxFileProto, wxT("file"), NULL, false)
wxFileProto::wxFileProto()
+ m_error = wxPROTO_NOERR;
}
wxFileProto::~wxFileProto()
}
wxFileProto::~wxFileProto()
wxInputStream *wxFileProto::GetInputStream(const wxString& path)
{
wxInputStream *wxFileProto::GetInputStream(const wxString& path)
{
- wxFileInputStream* retval = new wxFileInputStream(wxURI::Unescape(path));
- if (retval->Ok()) {
- return retval;
- } else {
+ wxFileInputStream *retval = new wxFileInputStream(wxURI::Unescape(path));
+ if ( retval->Ok() )
+ {
+ m_error = wxPROTO_NOERR;
+
+ return retval;
+ }
+
+ m_error = wxPROTO_NOFILE;
}
#endif // wxUSE_STREAMS && wxUSE_PROTOCOL_FILE
}
#endif // wxUSE_STREAMS && wxUSE_PROTOCOL_FILE