void WebViewTest::loadAlternateHTML(const char* html, const char* contentURI, const char* baseURI) { m_activeURI = contentURI; webkit_web_view_load_alternate_html(m_webView, html, contentURI, baseURI); #if 0 // FIXME: Pending API request URL no set when loading Alternate HTML. // See https://bugs.webkit.org/show_bug.cgi?id=136916. g_assert(webkit_web_view_is_loading(m_webView)); #endif g_assert_cmpstr(webkit_web_view_get_uri(m_webView), ==, m_activeURI.data()); }
gboolean load_error_page (WebKitWebView *web_view, const char *failing_uri, const char *title, const char *message) { g_warning ("<%s> %s: %s", failing_uri, title, message); g_autofree char *html = g_strdup_printf (error_message_template, title, title, failing_uri, message); webkit_web_view_load_alternate_html (web_view, html, failing_uri, NULL); return TRUE; }
void WebViewTest::loadAlternateHTML(const char* html, const char* contentURI, const char* baseURI) { m_activeURI = contentURI; webkit_web_view_load_alternate_html(m_webView, html, contentURI, baseURI); }