diff options
author | Steve Block <steveblock@google.com> | 2010-02-15 12:23:52 +0000 |
---|---|---|
committer | Steve Block <steveblock@google.com> | 2010-02-16 11:48:32 +0000 |
commit | 8a0914b749bbe7da7768e07a7db5c6d4bb09472b (patch) | |
tree | 73f9065f370435d6fde32ae129d458a8c77c8dff /WebKit/gtk | |
parent | bf14be70295513b8076f3fa47a268a7e42b2c478 (diff) | |
download | external_webkit-8a0914b749bbe7da7768e07a7db5c6d4bb09472b.zip external_webkit-8a0914b749bbe7da7768e07a7db5c6d4bb09472b.tar.gz external_webkit-8a0914b749bbe7da7768e07a7db5c6d4bb09472b.tar.bz2 |
Merge webkit.org at r54731 : Initial merge by git
Change-Id: Ia79977b6cf3b0b00c06ef39419989b28e57e4f4a
Diffstat (limited to 'WebKit/gtk')
-rw-r--r-- | WebKit/gtk/ChangeLog | 94 | ||||
-rw-r--r-- | WebKit/gtk/NEWS | 14 | ||||
-rw-r--r-- | WebKit/gtk/WebCoreSupport/FrameLoaderClientGtk.cpp | 53 | ||||
-rw-r--r-- | WebKit/gtk/tests/testwebview.c | 104 | ||||
-rw-r--r-- | WebKit/gtk/webkit/webkitprivate.h | 3 | ||||
-rw-r--r-- | WebKit/gtk/webkit/webkitwebframe.cpp | 26 | ||||
-rw-r--r-- | WebKit/gtk/webkit/webkitwebview.cpp | 63 |
7 files changed, 320 insertions, 37 deletions
diff --git a/WebKit/gtk/ChangeLog b/WebKit/gtk/ChangeLog index 92de7e4..7a44884 100644 --- a/WebKit/gtk/ChangeLog +++ b/WebKit/gtk/ChangeLog @@ -1,3 +1,97 @@ +2010-02-09 Gustavo Noronha Silva <gns@gnome.org> + + Reviewed by Xan Lopez. + + [GTK] Hits assertion on history back, with page cache enabled, in specific conditions + https://bugs.webkit.org/show_bug.cgi?id=34773 + + Make sure cached frames have their scrollbars disconnected from + the WebView's adjustments. + + * WebCoreSupport/FrameLoaderClientGtk.cpp: + (WebKit::FrameLoaderClient::savePlatformDataToCachedFrame): + +2010-02-09 Gustavo Noronha Silva <gustavo.noronha@collabora.co.uk> + + Reviewed by Xan Lopez. + + [GTK] Set GtkAdjustments on our FrameView when loading a page in the PageCache + https://bugs.webkit.org/show_bug.cgi?id=34754 + + Test that lower, and upper bounds are kept when goibg back with + page cache enabled, and disabled. Page cache behaviour is still a + bit broken (see FIXME). + + * tests/testwebview.c: + (server_callback): + (map_event_cb): + (do_test_webkit_web_view_adjustments): + (test_webkit_web_view_adjustments): + (main): + +2010-02-09 Xan Lopez <xlopez@igalia.com> + + Reviewed by Gustavo Noronha. + + [GTK] Set GtkAdjustments on our FrameView when loading a page in the PageCache + https://bugs.webkit.org/show_bug.cgi?id=34754 + + Set the Gtk Adjustments of the FrameViews when they are restored + from the PageCache too. Right we only do it for the newly created + FrameViews in transitionToCommittedForNewPage, but we it also + needs to be done in the equilavent transition method for cached + pages. + + * WebCoreSupport/FrameLoaderClientGtk.cpp: + (WebKit::postCommitFrameViewSetup): + (WebKit::FrameLoaderClient::transitionToCommittedFromCachedFrame): + (WebKit::FrameLoaderClient::transitionToCommittedForNewPage): + +2010-02-08 Xan Lopez <xlopez@igalia.com> + + Reviewed by Gustavo Noronha. + + [GTK] Implement FrameLoaderClient::hasWebView + https://bugs.webkit.org/show_bug.cgi?id=34682 + + Used for sanity-check ASSERTS in the FrameLoader code. + + * WebCoreSupport/FrameLoaderClientGtk.cpp: + (WebKit::FrameLoaderClient::hasWebView): + +2010-02-08 Gustavo Noronha Silva <gustavo.noronha@collabora.co.uk> + + Reviewed by Xan Lopez. + + News about 1.1.21. + + * NEWS: + +2010-02-05 Shinichiro Hamaji <hamaji@chromium.org> + + Reviewed by Gustavo Noronha Silva. + + [Gtk] Implement layoutTestController.pageNumberForElementById + https://bugs.webkit.org/show_bug.cgi?id=34572 + + * webkit/webkitprivate.h: + * webkit/webkitwebframe.cpp: + (webkit_web_frame_page_number_for_element_by_id): + +2010-02-04 Christian Dywan <christian@twotoasts.de> + + Reviewed by Gustavo Noronha Silva. + + [GTK] Add and cleanup return values of signals in view and frame + https://bugs.webkit.org/show_bug.cgi?id=33484 + + Add missing and cleanup return values of web frame and web view signals. + + * webkit/webkitwebframe.cpp: + (webkit_web_frame_class_init): + * webkit/webkitwebview.cpp: + (DNDContentsRequest::webkit_web_view_class_init): + 2010-02-02 Gustavo Noronha Silva <gns@gnome.org> Reviewed by Xan Lopez. diff --git a/WebKit/gtk/NEWS b/WebKit/gtk/NEWS index 807fca4..4e5bc2c 100644 --- a/WebKit/gtk/NEWS +++ b/WebKit/gtk/NEWS @@ -1,4 +1,18 @@ ================= +WebKitGTK+ 1.1.21 +================= + +What's new in WebKitGTK+ 1.1.21? + + - New custom-made GStreamer source element that uses the WebCore + network layer to download media data; this makes sure any headers + and cookies will automatically get added when making requests. + - WebKit will now let libsoup know who the first party for a given + message is, making it possible to implement accept/deny policies in + Soup. + - The usual stream of fixes, and improvements + +================= WebKitGTK+ 1.1.20 ================= diff --git a/WebKit/gtk/WebCoreSupport/FrameLoaderClientGtk.cpp b/WebKit/gtk/WebCoreSupport/FrameLoaderClientGtk.cpp index 8f1bec2..1ccc8a1 100644 --- a/WebKit/gtk/WebCoreSupport/FrameLoaderClientGtk.cpp +++ b/WebKit/gtk/WebCoreSupport/FrameLoaderClientGtk.cpp @@ -3,7 +3,7 @@ * Copyright (C) 2007, 2008, 2009 Holger Hans Peter Freyther * Copyright (C) 2007 Christian Dywan <christian@twotoasts.de> * Copyright (C) 2008, 2009 Collabora Ltd. All rights reserved. - * Copyright (C) 2009 Gustavo Noronha Silva <gns@gnome.org> + * Copyright (C) 2009, 2010 Gustavo Noronha Silva <gns@gnome.org> * Copyright (C) Research In Motion Limited 2009. All rights reserved. * * This library is free software; you can redistribute it and/or @@ -25,6 +25,7 @@ #include "FrameLoaderClientGtk.h" #include "ArchiveResource.h" +#include "CachedFrame.h" #include "Color.h" #include "DocumentLoader.h" #include "DocumentLoaderGtk.h" @@ -563,8 +564,7 @@ void FrameLoaderClient::setMainFrameDocumentReady(bool) bool FrameLoaderClient::hasWebView() const { - notImplemented(); - return true; + return getViewFromFrame(m_frame); } void FrameLoaderClient::dispatchDidFinishLoad() @@ -646,9 +646,7 @@ void FrameLoaderClient::setCopiesOnScroll() void FrameLoaderClient::detachedFromParent2() { - FrameView *view = core(m_frame)->view(); - if (view) - view->setGtkAdjustments(0, 0); + notImplemented(); } void FrameLoaderClient::detachedFromParent3() @@ -1116,12 +1114,40 @@ void FrameLoaderClient::updateGlobalHistoryRedirectLinks() notImplemented(); } -void FrameLoaderClient::savePlatformDataToCachedFrame(CachedFrame*) +void FrameLoaderClient::savePlatformDataToCachedFrame(CachedFrame* cachedFrame) +{ + // We need to do this here in order to disconnect the scrollbars + // that are being used by the frame that is being cached from the + // adjustments, otherwise they will react to changes in the + // adjustments, and bad things will happen. + if (cachedFrame->view()) + cachedFrame->view()->setGtkAdjustments(0, 0); +} + +static void postCommitFrameViewSetup(WebKitWebFrame *frame, FrameView *view, bool resetValues) { + WebKitWebView* containingWindow = getViewFromFrame(frame); + WebKitWebViewPrivate* priv = WEBKIT_WEB_VIEW_GET_PRIVATE(containingWindow); + view->setGtkAdjustments(priv->horizontalAdjustment, priv->verticalAdjustment, resetValues); + + if (priv->currentMenu) { + GtkMenu* menu = priv->currentMenu; + priv->currentMenu = 0; + + gtk_menu_popdown(menu); + g_object_unref(menu); + } } -void FrameLoaderClient::transitionToCommittedFromCachedFrame(CachedFrame*) +void FrameLoaderClient::transitionToCommittedFromCachedFrame(CachedFrame* cachedFrame) { + ASSERT(cachedFrame->view()); + + Frame* frame = core(m_frame); + if (frame != frame->page()->mainFrame()) + return; + + postCommitFrameViewSetup(m_frame, cachedFrame->view(), false); } void FrameLoaderClient::transitionToCommittedForNewPage() @@ -1140,16 +1166,7 @@ void FrameLoaderClient::transitionToCommittedForNewPage() if (frame != frame->page()->mainFrame()) return; - WebKitWebViewPrivate* priv = WEBKIT_WEB_VIEW_GET_PRIVATE(containingWindow); - frame->view()->setGtkAdjustments(priv->horizontalAdjustment, priv->verticalAdjustment); - - if (priv->currentMenu) { - GtkMenu* menu = priv->currentMenu; - priv->currentMenu = NULL; - - gtk_menu_popdown(menu); - g_object_unref(menu); - } + postCommitFrameViewSetup(m_frame, frame->view(), true); } } diff --git a/WebKit/gtk/tests/testwebview.c b/WebKit/gtk/tests/testwebview.c index 7482747..c028a36 100644 --- a/WebKit/gtk/tests/testwebview.c +++ b/WebKit/gtk/tests/testwebview.c @@ -55,6 +55,12 @@ server_callback(SoupServer* server, SoupMessage* msg, g_assert(!error); soup_message_body_append(msg->response_body, SOUP_MEMORY_TAKE, contents, length); + } else if (g_str_equal(path, "/bigdiv.html")) { + char* contents = g_strdup("<html><body><div style=\"background-color: green; height: 1200px;\"></div></body></html>"); + soup_message_body_append(msg->response_body, SOUP_MEMORY_TAKE, contents, strlen(contents)); + } else if (g_str_equal(path, "/iframe.html")) { + char* contents = g_strdup("<html><body><div style=\"background-color: green; height: 50px;\"></div><iframe src=\"bigdiv.html\"></iframe></body></html>"); + soup_message_body_append(msg->response_body, SOUP_MEMORY_TAKE, contents, strlen(contents)); } else { char* contents = g_strdup("<html><body>test</body></html>"); soup_message_body_append(msg->response_body, SOUP_MEMORY_TAKE, contents, strlen(contents)); @@ -121,6 +127,103 @@ static void test_webkit_web_view_icon_uri() g_object_unref(view); } +static gboolean map_event_cb(GtkWidget *widget, GdkEvent* event, gpointer data) +{ + GMainLoop* loop = (GMainLoop*)data; + g_main_loop_quit(loop); + + return FALSE; +} + +static void do_test_webkit_web_view_adjustments(gboolean with_page_cache) +{ + char* effective_uri = g_strconcat(base_uri, "bigdiv.html", NULL); + char* second_uri = g_strconcat(base_uri, "iframe.html", NULL); + GtkWidget* window = gtk_window_new(GTK_WINDOW_TOPLEVEL); + GtkWidget* scrolled_window = gtk_scrolled_window_new(NULL, NULL); + WebKitWebView* view = WEBKIT_WEB_VIEW(webkit_web_view_new()); + GtkAdjustment* adjustment; + double lower; + double upper; + + if (with_page_cache) { + WebKitWebSettings* settings = webkit_web_view_get_settings(view); + g_object_set(settings, "enable-page-cache", TRUE, NULL); + } + + gtk_window_set_default_size(GTK_WINDOW(window), 400, 200); + + gtk_container_add(GTK_CONTAINER(window), scrolled_window); + gtk_container_add(GTK_CONTAINER(scrolled_window), GTK_WIDGET(view)); + + gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(scrolled_window), + GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC); + + loop = g_main_loop_new(NULL, TRUE); + + g_object_connect(G_OBJECT(view), + "signal::notify::progress", idle_quit_loop_cb, NULL, + NULL); + + /* Wait for window to show up */ + gtk_widget_show_all(window); + g_signal_connect(window, "map-event", + G_CALLBACK(map_event_cb), loop); + g_main_loop_run(loop); + + /* Load a page with a big div that will cause scrollbars to appear */ + webkit_web_view_load_uri(view, effective_uri); + g_main_loop_run(loop); + + adjustment = gtk_scrolled_window_get_vadjustment(GTK_SCROLLED_WINDOW(scrolled_window)); + g_assert_cmpfloat(gtk_adjustment_get_value(adjustment), ==, 0.0); + + lower = gtk_adjustment_get_lower(adjustment); + upper = gtk_adjustment_get_upper(adjustment); + + /* Scroll the view using JavaScript */ + webkit_web_view_execute_script(view, "window.scrollBy(0, 100)"); + + /* Make sure the ScrolledWindow noticed the scroll */ + g_assert_cmpfloat(gtk_adjustment_get_value(adjustment), ==, 100.0); + + /* Load a second URI */ + webkit_web_view_load_uri(view, second_uri); + g_main_loop_run(loop); + + /* Make sure the scrollbar has been reset */ + g_assert_cmpfloat(gtk_adjustment_get_value(adjustment), ==, 0.0); + + /* Go back */ + webkit_web_view_go_back(view); + + /* When using page cache, go_back will return syncronously */ + if (!with_page_cache) + g_main_loop_run(loop); + + /* Make sure GTK+ has time to process the changes in size, for the adjusments */ + while (gtk_events_pending()) + gtk_main_iteration(); + + /* Make sure upper and lower bounds have been restored correctly */ + g_assert_cmpfloat(lower, ==, gtk_adjustment_get_lower(adjustment)); + g_assert_cmpfloat(upper, ==, gtk_adjustment_get_upper(adjustment)); + + g_assert_cmpfloat(gtk_adjustment_get_value(adjustment), ==, 100.0); + + g_free(effective_uri); + g_free(second_uri); + + gtk_widget_destroy(window); +} + +static void test_webkit_web_view_adjustments() +{ + /* Test this with page cache disabled, and enabled. */ + do_test_webkit_web_view_adjustments(FALSE); + do_test_webkit_web_view_adjustments(TRUE); +} + int main(int argc, char** argv) { SoupServer* server; @@ -153,6 +256,7 @@ int main(int argc, char** argv) g_test_bug_base("https://bugs.webkit.org/"); g_test_add_func("/webkit/webview/icon-uri", test_webkit_web_view_icon_uri); + g_test_add_func("/webkit/webview/adjustments", test_webkit_web_view_adjustments); return g_test_run (); } diff --git a/WebKit/gtk/webkit/webkitprivate.h b/WebKit/gtk/webkit/webkitprivate.h index e9d61a6..44b4d0c 100644 --- a/WebKit/gtk/webkit/webkitprivate.h +++ b/WebKit/gtk/webkit/webkitprivate.h @@ -298,6 +298,9 @@ extern "C" { WEBKIT_API gchar* webkit_web_frame_counter_value_for_element_by_id (WebKitWebFrame* frame, const gchar* id); + WEBKIT_API int + webkit_web_frame_page_number_for_element_by_id(WebKitWebFrame* frame, const gchar* id, float pageWidth, float pageHeight); + WEBKIT_API guint webkit_web_frame_get_pending_unload_event_count(WebKitWebFrame* frame); diff --git a/WebKit/gtk/webkit/webkitwebframe.cpp b/WebKit/gtk/webkit/webkitwebframe.cpp index 35d9524..fbd246d 100644 --- a/WebKit/gtk/webkit/webkitwebframe.cpp +++ b/WebKit/gtk/webkit/webkitwebframe.cpp @@ -269,6 +269,9 @@ static void webkit_web_frame_class_init(WebKitWebFrameClass* frameClass) * WebKitWebFrame:horizontal-scrollbar-policy and * WebKitWebFrame:vertical-scrollbar-policy properties. * + * Return value: %TRUE to stop other handlers from being invoked for the + * event. %FALSE to propagate the event further. + * * Since: 1.1.14 */ webkit_web_frame_signals[SCROLLBARS_POLICY_CHANGED] = g_signal_new("scrollbars-policy-changed", @@ -841,6 +844,29 @@ gchar* webkit_web_frame_counter_value_for_element_by_id(WebKitWebFrame* frame, c } /** + * webkit_web_frame_page_number_for_element_by_id + * @frame: a #WebKitWebFrame + * @id: an element ID string + * @pageWidth: width of a page + * @pageHeight: height of a page + * + * Return value: The number of page where the specified element will be put + */ +int webkit_web_frame_page_number_for_element_by_id(WebKitWebFrame* frame, const gchar* id, float pageWidth, float pageHeight) +{ + g_return_val_if_fail(WEBKIT_IS_WEB_FRAME(frame), NULL); + + Frame* coreFrame = core(frame); + if (!coreFrame) + return -1; + + Element* coreElement = coreFrame->document()->getElementById(AtomicString(id)); + if (!coreElement) + return -1; + return PrintContext::pageNumberForElement(coreElement, FloatSize(pageWidth, pageHeight)); +} + +/** * webkit_web_frame_get_pending_unload_event_count: * @frame: a #WebKitWebFrame * diff --git a/WebKit/gtk/webkit/webkitwebview.cpp b/WebKit/gtk/webkit/webkitwebview.cpp index ad13895..8c5b802 100644 --- a/WebKit/gtk/webkit/webkitwebview.cpp +++ b/WebKit/gtk/webkit/webkitwebview.cpp @@ -1325,7 +1325,6 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * WebKitWebView::create-web-view: * @web_view: the object on which the signal is emitted * @frame: the #WebKitWebFrame - * @return: a newly allocated #WebKitWebView or %NULL * * Emitted when the creation of a new window is requested. * If this signal is handled the signal handler should return the @@ -1338,6 +1337,8 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * the new #WebKitWebView. The widget to which the widget is added will * handle that. * + * Return value: a newly allocated #WebKitWebView, or %NULL + * * Since: 1.0.3 */ webkit_web_view_signals[CREATE_WEB_VIEW] = g_signal_new("create-web-view", @@ -1353,8 +1354,6 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) /** * WebKitWebView::web-view-ready: * @web_view: the object on which the signal is emitted - * @return: %TRUE to stop other handlers from being invoked for - * the event, %FALSE to propagate the event further * * Emitted after #WebKitWebView::create-web-view when the new #WebKitWebView * should be displayed to the user. When this signal is emitted @@ -1367,6 +1366,9 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * time of the window, so you may want to connect to the ::notify * signal of the #WebKitWebWindowFeatures object to handle those. * + * Return value: %TRUE to stop handlers from being invoked for the event or + * %FALSE to propagate the event furter + * * Since: 1.0.3 */ webkit_web_view_signals[WEB_VIEW_READY] = g_signal_new("web-view-ready", @@ -1381,14 +1383,15 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) /** * WebKitWebView::close-web-view: * @web_view: the object on which the signal is emitted - * @return: %TRUE to stop handlers from being invoked for the event or - * %FALSE to propagate the event furter * * Emitted when closing a #WebKitWebView is requested. This occurs when a * call is made from JavaScript's window.close function. The default * signal handler does not do anything. It is the owner's responsibility * to hide or delete the web view, if necessary. * + * Return value: %TRUE to stop handlers from being invoked for the event or + * %FALSE to propagate the event furter + * * Since: 1.1.11 */ webkit_web_view_signals[CLOSE_WEB_VIEW] = g_signal_new("close-web-view", @@ -1405,10 +1408,11 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * @web_view: the object on which the signal is emitted * @frame: the #WebKitWebFrame that required the navigation * @request: a #WebKitNetworkRequest - * @return: a WebKitNavigationResponse * * Emitted when @frame requests a navigation to another page. * + * Return value: a #WebKitNavigationResponse + * * Deprecated: Use WebKitWebView::navigation-policy-decision-requested * instead */ @@ -1430,8 +1434,6 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * @request: a #WebKitNetworkRequest * @navigation_action: a #WebKitWebNavigation * @policy_decision: a #WebKitWebPolicyDecision - * @return: TRUE if a decision was made, FALSE to have the - * default behavior apply * * Emitted when @frame requests opening a new window. With this * signal the browser can use the context of the request to decide @@ -1453,6 +1455,9 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * webkit_web_policy_decision_download() on the @policy_decision * object. * + * Return value: %TRUE if a decision was made, %FALSE to have the + * default behavior apply + * * Since: 1.1.4 */ webkit_web_view_signals[NEW_WINDOW_POLICY_DECISION_REQUESTED] = @@ -1476,8 +1481,6 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * @request: a #WebKitNetworkRequest * @navigation_action: a #WebKitWebNavigation * @policy_decision: a #WebKitWebPolicyDecision - * @return: TRUE if a decision was made, FALSE to have the - * default behavior apply * * Emitted when @frame requests a navigation to another page. * If this signal is not handled, the default behavior is to allow the @@ -1490,6 +1493,9 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * webkit_web_policy_decision_download() on the @policy_decision * object. * + * Return value: %TRUE if a decision was made, %FALSE to have the + * default behavior apply + * * Since: 1.0.3 */ webkit_web_view_signals[NAVIGATION_POLICY_DECISION_REQUESTED] = g_signal_new("navigation-policy-decision-requested", @@ -1512,8 +1518,6 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * @request: a WebKitNetworkRequest * @mimetype: the MIME type attempted to load * @policy_decision: a #WebKitWebPolicyDecision - * @return: TRUE if a decision was made, FALSE to have the - * default behavior apply * * Decide whether or not to display the given MIME type. If this * signal is not handled, the default behavior is to show the @@ -1531,6 +1535,9 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * webkit_web_policy_decision_download() on the @policy_decision * object. * + * Return value: %TRUE if a decision was made, %FALSE to have the + * default behavior apply + * * Since: 1.0.3 */ webkit_web_view_signals[MIME_TYPE_POLICY_DECISION_REQUESTED] = g_signal_new("mime-type-policy-decision-requested", @@ -1578,7 +1585,6 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * @web_view: the object on which the signal is emitted * @download: a #WebKitDownload object that lets you control the * download process - * @return: %TRUE if the download should be performed, %FALSE to cancel it. * * A new Download is being requested. By default, if the signal is * not handled, the download is cancelled. If you handle the download @@ -1601,6 +1607,9 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * is to download anything that WebKit can't handle, which you can * figure out by using webkit_web_view_can_show_mime_type()). * + * Return value: TRUE if the download should be performed, %FALSE to + * cancel it + * * Since: 1.1.2 */ webkit_web_view_signals[DOWNLOAD_REQUESTED] = g_signal_new("download-requested", @@ -1681,6 +1690,9 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * handle the signal if you want to provide your own error page. * * Since: 1.1.6 + * + * Return value: %TRUE to stop other handlers from being invoked for the + * event. %FALSE to propagate the event further. */ webkit_web_view_signals[LOAD_ERROR] = g_signal_new("load-error", G_TYPE_FROM_CLASS(webViewClass), @@ -1774,8 +1786,6 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * WebKitWebView::print-requested * @web_view: the object in which the signal is emitted * @web_frame: the frame that is requesting to be printed - * @return: %TRUE if the print request has been handled, %FALSE if - * the default handler should run * * Emitted when printing is requested by the frame, usually * because of a javascript call. When handling this signal you @@ -1787,6 +1797,9 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * ignore a print request you must connect to this signal, and * return %TRUE. * + * Return value: %TRUE if the print request has been handled, %FALSE if + * the default handler should run + * * Since: 1.1.5 */ webkit_web_view_signals[PRINT_REQUESTED] = g_signal_new("print-requested", @@ -1843,9 +1856,11 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * @message: the message text * @line: the line where the error occured * @source_id: the source id - * @return: TRUE to stop other handlers from being invoked for the event. FALSE to propagate the event further. * * A JavaScript console message was created. + * + * Return value: %TRUE to stop other handlers from being invoked for the + * event. %FALSE to propagate the event further. */ webkit_web_view_signals[CONSOLE_MESSAGE] = g_signal_new("console-message", G_TYPE_FROM_CLASS(webViewClass), @@ -1862,9 +1877,11 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * @web_view: the object on which the signal is emitted * @frame: the relevant frame * @message: the message text - * @return: TRUE to stop other handlers from being invoked for the event. FALSE to propagate the event further. * * A JavaScript alert dialog was created. + * + * Return value: %TRUE to stop other handlers from being invoked for the + * event. %FALSE to propagate the event further. */ webkit_web_view_signals[SCRIPT_ALERT] = g_signal_new("script-alert", G_TYPE_FROM_CLASS(webViewClass), @@ -1882,9 +1899,11 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * @frame: the relevant frame * @message: the message text * @confirmed: whether the dialog has been confirmed - * @return: TRUE to stop other handlers from being invoked for the event. FALSE to propagate the event further. * * A JavaScript confirm dialog was created, providing Yes and No buttons. + * + * Return value: %TRUE to stop other handlers from being invoked for the + * event. %FALSE to propagate the event further. */ webkit_web_view_signals[SCRIPT_CONFIRM] = g_signal_new("script-confirm", G_TYPE_FROM_CLASS(webViewClass), @@ -1903,9 +1922,11 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * @message: the message text * @default: the default value * @text: To be filled with the return value or NULL if the dialog was cancelled. - * @return: TRUE to stop other handlers from being invoked for the event. FALSE to propagate the event further. * * A JavaScript prompt dialog was created, providing an entry to input text. + * + * Return value: %TRUE to stop other handlers from being invoked for the + * event. %FALSE to propagate the event further. */ webkit_web_view_signals[SCRIPT_PROMPT] = g_signal_new("script-prompt", G_TYPE_FROM_CLASS(webViewClass), @@ -2032,6 +2053,8 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * * The #WebKitWebView::move-cursor will be emitted to apply the * cursor movement described by its parameters to the @view. + * + * Return value: %TRUE or %FALSE * * Since: 1.1.4 */ @@ -2059,6 +2082,8 @@ static void webkit_web_view_class_init(WebKitWebViewClass* webViewClass) * to set the property value of "webkit-widget-is-selected". This can * be used to draw a visual indicator of the selection. * + * Return value: a new #GtkWidget, or %NULL + * * Since: 1.1.8 */ webkit_web_view_signals[PLUGIN_WIDGET] = g_signal_new("create-plugin-widget", |