RESOLVED FIXED35727
[GTK] GTK_WIDGET_NO_WINDOW deprecated in GTK+ 2.20
https://bugs.webkit.org/show_bug.cgi?id=35727
Summary [GTK] GTK_WIDGET_NO_WINDOW deprecated in GTK+ 2.20
Philippe Normand
Reported 2010-03-04 01:32:06 PST
We should use gtk_widget_set_has_window() instead if GTK version is >= 2.18.
Attachments
proposed patch (4.41 KB, patch)
2010-03-04 02:08 PST, Philippe Normand
eric: review-
proposed patch (6.36 KB, patch)
2010-03-08 00:46 PST, Philippe Normand
gustavo: review-
Philippe Normand
Comment 1 2010-03-04 01:33:31 PST
I meant gtk_widget_get_has_window of course :)
Philippe Normand
Comment 2 2010-03-04 02:08:24 PST
Created attachment 49999 [details] proposed patch
Eric Seidel (no email)
Comment 3 2010-03-05 13:17:39 PST
Comment on attachment 49999 [details] proposed patch Can we wrap this in some helper function? Copy/paste 4 times seems silly. Even if we just used a helper function in GtkWidget.cpp that would be better than this.
Philippe Normand
Comment 4 2010-03-08 00:46:19 PST
Created attachment 50195 [details] proposed patch
Gustavo Noronha (kov)
Comment 5 2010-03-08 13:56:02 PST
Comment on attachment 50195 [details] proposed patch  24 #if GTK_CHECK_VERSION(2, 18, 0)  25 #define WIDGET_HAS_WINDOW(widget) gtk_widget_get_has_window(widget)  26 #else  27 #define WIDGET_HAS_WINDOW(widget) !GTK_WIDGET_NO_WINDOW(widget) I think creating a utils file just for this is not worth it. Why not add a function to the WidgetGtk class (or file), as Eric suggested?  691 #if GTK_CHECK_VERSION(2, 18, 0)  692 if (gtk_widget_is_sensitive(widget)) {  693 #else 691694 if (GTK_WIDGET_IS_SENSITIVE(widget)) {  695 #endif This is unrelated. Please put it into another patch.
Philippe Normand
Comment 6 2010-03-09 00:21:05 PST
(In reply to comment #5) > (From update of attachment 50195 [details]) >  24 #if GTK_CHECK_VERSION(2, 18, 0) >  25 #define WIDGET_HAS_WINDOW(widget) gtk_widget_get_has_window(widget) >  26 #else >  27 #define WIDGET_HAS_WINDOW(widget) !GTK_WIDGET_NO_WINDOW(widget) > > I think creating a utils file just for this is not worth it. Why not add a > function to the WidgetGtk class (or file), as Eric suggested? > Ok can you tell me what you want exactly? a method of the class or a static function? >  691 #if GTK_CHECK_VERSION(2, 18, 0) >  692 if (gtk_widget_is_sensitive(widget)) { >  693 #else > 691694 if (GTK_WIDGET_IS_SENSITIVE(widget)) { >  695 #endif > > This is unrelated. Please put it into another patch. I just put it in this patch because it was fixing my build for the same reasons (gtk deprecating apis)... but yeah fine, it just adds one patch in the queue :P
Note You need to log in before you can comment on or make changes to this bug.