Rename wxWebFileHandler to wxWebViewArchiveHandler, wxWebHandler to wxWebViewHandler. Update the documentation and the sample. Add a constructor taking a wxString to specify the scheme in wxWebViewHandler.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68689 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Steve Lamerton
2011-08-14 12:15:34 +00:00
parent 3beb50e570
commit 7d8d6163ad
12 changed files with 62 additions and 56 deletions

View File

@@ -104,10 +104,10 @@ wxgtk_webview_webkit_navigation(WebKitWebView *,
else
{
wxString wxuri = uri;
wxSharedPtr<wxWebHandler> handler;
wxVector<wxSharedPtr<wxWebHandler> > hanlders = webKitCtrl->GetHandlers();
wxSharedPtr<wxWebViewHandler> handler;
wxVector<wxSharedPtr<wxWebViewHandler> > hanlders = webKitCtrl->GetHandlers();
//We are not vetoed so see if we match one of the additional handlers
for(wxVector<wxSharedPtr<wxWebHandler> >::iterator it = hanlders.begin();
for(wxVector<wxSharedPtr<wxWebViewHandler> >::iterator it = hanlders.begin();
it != hanlders.end(); ++it)
{
if(wxuri.substr(0, (*it)->GetName().length()) == (*it)->GetName())
@@ -329,11 +329,11 @@ wxgtk_webview_webkit_resource_req(WebKitWebView *,
{
wxString uri = webkit_network_request_get_uri(request);
wxSharedPtr<wxWebHandler> handler;
wxVector<wxSharedPtr<wxWebHandler> > hanlders = webKitCtrl->GetHandlers();
wxSharedPtr<wxWebViewHandler> handler;
wxVector<wxSharedPtr<wxWebViewHandler> > hanlders = webKitCtrl->GetHandlers();
//We are not vetoed so see if we match one of the additional handlers
for(wxVector<wxSharedPtr<wxWebHandler> >::iterator it = hanlders.begin();
for(wxVector<wxSharedPtr<wxWebViewHandler> >::iterator it = hanlders.begin();
it != hanlders.end(); ++it)
{
if(uri.substr(0, (*it)->GetName().length()) == (*it)->GetName())
@@ -911,7 +911,7 @@ void wxWebViewWebKit::RunScript(const wxString& javascript)
javascript.mb_str(wxConvUTF8));
}
void wxWebViewWebKit::RegisterHandler(wxSharedPtr<wxWebHandler> handler)
void wxWebViewWebKit::RegisterHandler(wxSharedPtr<wxWebViewHandler> handler)
{
m_handlerList.push_back(handler);
}