Bug 59990

Summary: [GTK][WebKit2] GTK+ 2.x widget rendering fails after r85480
Product: WebKit Reporter: Martin Robinson <mrobinson>
Component: WebKitGTKAssignee: Martin Robinson <mrobinson>
Status: RESOLVED FIXED    
Severity: Normal CC: alex, cgarcia, pnormand, webkit.review.bot, xan.lopez
Priority: P3 Keywords: Gtk
Version: 528+ (Nightly build)   
Hardware: PC   
OS: Linux   
Attachments:
Description Flags
Patch none

Description Martin Robinson 2011-05-02 17:57:14 PDT
It seems the issue here is that there are two situations that are no longer handled by the code grabbing the drawable size:

1. When the drawable is null.
2. When the drawable is in fact a GdkPixmap.

For the time being this diables the sanity check for WebKit2, but we can wait to add support for that when we decide whether or not to drop GTK+ 2.x support for WebKit2.
Comment 1 Martin Robinson 2011-05-02 17:59:23 PDT
Created attachment 92019 [details]
Patch
Comment 2 Martin Robinson 2011-05-02 17:59:51 PDT
Style bot: We have to keep the parameter name because this header is used in C code.
Comment 3 WebKit Review Bot 2011-05-02 18:02:10 PDT
Attachment 92019 [details] did not pass style-queue:

Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WebCore/ChangeLog', u'Source/WebCor..." exit_code: 1

Source/WebCore/platform/gtk/GtkVersioning.h:38:  The parameter name "drawable" adds no information, so it should be removed.  [readability/parameter_name] [5]
Total errors found: 1 in 4 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 4 Xan Lopez 2011-05-09 12:34:06 PDT
Comment on attachment 92019 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=92019&action=review

> Source/WebCore/platform/gtk/GtkVersioning.c:267
> +    g_assert(GDK_IS_PIXMAP(drawable) || GDK_IS_WINDOW(drawable));

This will crash in release builds, so better change it for g_return_if_fail.
Comment 5 Martin Robinson 2011-05-10 12:37:37 PDT
Committed r86178: <http://trac.webkit.org/changeset/86178>