X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/9d2f31db0c8c611af9f80efa5237f5479388350b..21317c46b4eb3e0f174a82c57f268c102b25b9d1:/src/gtk/webview_webkit.cpp diff --git a/src/gtk/webview_webkit.cpp b/src/gtk/webview_webkit.cpp index 08199cd778..8b249a8062 100644 --- a/src/gtk/webview_webkit.cpp +++ b/src/gtk/webview_webkit.cpp @@ -18,7 +18,7 @@ #include "wx/gtk/private.h" #include "wx/filesys.h" #include "wx/base64.h" -#include "webkit/webkit.h" +#include // ---------------------------------------------------------------------------- // GTK callbacks @@ -50,7 +50,12 @@ wxgtk_webview_webkit_load_status(GtkWidget* widget, //with a custom scheme. if(WEBKIT_IS_WEB_HISTORY_ITEM(item) && webkit_web_history_item_get_uri(item) != url) { - WebKitWebHistoryItem* newitem = webkit_web_history_item_new_with_data(url, webKitCtrl->GetCurrentTitle()); + WebKitWebHistoryItem* + newitem = webkit_web_history_item_new_with_data + ( + url.utf8_str(), + webKitCtrl->GetCurrentTitle().utf8_str() + ); webkit_web_back_forward_list_add_item(hist, newitem); } @@ -368,7 +373,7 @@ wxgtk_webview_webkit_resource_req(WebKitWebView *, wxString mime = file->GetMimeType(); wxString path = "data:" + mime + ";base64," + data; //Then we can redirect the call - webkit_network_request_set_uri(request, path); + webkit_network_request_set_uri(request, path.utf8_str()); } } @@ -437,7 +442,7 @@ bool wxWebViewWebKit::Create(wxWindow *parent, PostCreation(size); /* Open a webpage */ - webkit_web_view_load_uri (WEBKIT_WEB_VIEW (web_view), url); + webkit_web_view_load_uri (WEBKIT_WEB_VIEW (web_view), url.utf8_str()); //Get the initial history limit so we can enable and disable it later WebKitWebBackForwardList* history; @@ -598,11 +603,9 @@ wxVector > wxWebViewWebKit::GetForwardHistory( void wxWebViewWebKit::LoadHistoryItem(wxSharedPtr item) { - WebKitWebHistoryItem* gtkitem = item->m_histItem; + WebKitWebHistoryItem* gtkitem = (WebKitWebHistoryItem*)item->m_histItem; if(gtkitem) { - WebKitWebBackForwardList* history; - history = webkit_web_view_get_back_forward_list(WEBKIT_WEB_VIEW(web_view)); webkit_web_view_go_to_back_forward_item(WEBKIT_WEB_VIEW(web_view), WEBKIT_WEB_HISTORY_ITEM(gtkitem)); }