[Webkit-unassigned] [Bug 96477] [WK2][GTK] Add API to get the favicon for a WebKitWebView

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Sep 12 06:45:43 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=96477





--- Comment #2 from Carlos Garcia Campos <cgarcia at igalia.com>  2012-09-12 06:46:09 PST ---
(From update of attachment 163601)
View in context: https://bugs.webkit.org/attachment.cgi?id=163601&action=review

Add webkit_web_view_get_favicon to webkit2gtk-sections.txt file.

> Source/WebKit2/UIProcess/API/gtk/WebKitFaviconDatabase.cpp:155
> +cairo_surface_t* webkitFaviconDatabaseGetFaviconSync(WebKitFaviconDatabase* database, const CString& pageURL)

Remove the Sync suffix, it's private api and we know it's sync.

> Source/WebKit2/UIProcess/API/gtk/WebKitWebView.cpp:254
> +void webkitWebViewIconReadyCallback(WebKitFaviconDatabase *database, const char *uri, WebKitWebView *webView)

This should be static

> Source/WebKit2/UIProcess/API/gtk/WebKitWebView.cpp:1797
> + * Returns favicon currently associated to @web_view, if any. The
> + * favicon might change during a load operation, but you can monitor
> + * those changes by connecting to the notify::favicon signal of
> + * @web_view.

Instead of might change, I would use something similar to other methods in WebKitWebView. 

You can connect to notify::favicon signal of @web_view to be notified when the favicon is available.

> Source/WebKit2/UIProcess/API/gtk/WebKitWebView.cpp:1800
> + * Returns: (transfer full): the favicon currently associated the
> + *    @web_view or %NULL if no favicon has been associated yet.

You should mention it's a #cairo_surface_t what is returned.

> Source/WebKit2/UIProcess/API/gtk/WebKitWebView.h:254
> +webkit_web_view_get_favicon                        (WebKitWebView*             webView);

WebKitWebView*             webView -> WebKitWebView             *webView

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the webkit-unassigned mailing list