Added wxInternetFilesystemModule to fs_inet.cpp
Fixed PROXY support in wxURL, wxHTTP. You can set the environement variable HTTP_PROXY now. Fixed parsing of content type in wxHtmlFilter Added commments to gsocket.c wxURL parses the URL only once now. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@3180 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -83,7 +83,7 @@ wxFSFile* wxInternetFSHandler::OpenFile(wxFileSystem& WXUNUSED(fs), const wxStri
|
||||
info = (wxInetCacheNode*) m_Cache.Get(right);
|
||||
|
||||
// Add item into cache:
|
||||
if (info != NULL)
|
||||
if (info == NULL)
|
||||
{
|
||||
wxURL url(right);
|
||||
s = url.GetInputStream();
|
||||
@@ -137,4 +137,19 @@ wxInternetFSHandler::~wxInternetFSHandler()
|
||||
}
|
||||
}
|
||||
|
||||
class wxFileSystemInternetModule : public wxModule
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxFileSystemInternetModule)
|
||||
|
||||
public:
|
||||
virtual bool OnInit()
|
||||
{
|
||||
wxFileSystem::AddHandler(new wxInternetFSHandler);
|
||||
return TRUE;
|
||||
}
|
||||
virtual void OnExit() {}
|
||||
};
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS(wxFileSystemInternetModule, wxModule)
|
||||
|
||||
#endif // wxUSE_FS_INET
|
||||
|
Reference in New Issue
Block a user