[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
alex at webkit.org
alex at webkit.org
Wed Dec 22 12:48:02 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit 72d5dce44fa452436bbe72a3406c286cd236c74f
Author: alex at webkit.org <alex at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Mon Aug 30 19:06:06 2010 +0000
2010-08-30 Alejandro G. Castro <alex at igalia.com>
Reviewed by Martin Robinson.
[Gtk] gdk_display_get_core_pointer and gdk_device_get_core_pointer
are deprecated
https://bugs.webkit.org/show_bug.cgi?id=44787
We have replaced GtkVersioning.cpp with GtkVersioning.c and
created a function (getDefaultGDKPointerDevice) to get the pointer
of the window with the new APIs. We added that function to DRT and
copyandpaste unit test.
* GNUmakefile.am:
* platform/gtk/GtkVersioning.c: Added.
(gtk_adjustment_set_value):
(gtk_adjustment_configure):
(getDefaultGDKPointerDevice):
* platform/gtk/GtkVersioning.cpp: Removed.
* platform/gtk/GtkVersioning.h:
2010-08-30 Alejandro G. Castro <alex at igalia.com>
Reviewed by Martin Robinson.
[Gtk] gdk_display_get_core_pointer and gdk_device_get_core_pointer
are deprecated
https://bugs.webkit.org/show_bug.cgi?id=44787
We have replaced GtkVersioning.cpp with GtkVersioning.c and
created a function (getDefaultGDKPointerDevice) to get the pointer
of the window with the new APIs. We added that function to DRT and
copyandpaste unit test.
* GNUmakefile.am:
2010-08-30 Alejandro G. Castro <alex at igalia.com>
Reviewed by Martin Robinson.
[Gtk] gdk_display_get_core_pointer and gdk_device_get_core_pointer
are deprecated
https://bugs.webkit.org/show_bug.cgi?id=44787
We have replaced GtkVersioning.cpp with GtkVersioning.c and
created a function (getDefaultGDKPointerDevice) to get the pointer
of the window with the new APIs. We added that function to DRT and
copyandpaste unit test.
* DumpRenderTree/gtk/EventSender.cpp:
(prepareMouseButtonEvent):
(mouseMoveToCallback):
(keyDownCallback):
* GNUmakefile.am:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@66398 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/ChangeLog b/ChangeLog
index eaab040..7d9fb36 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,18 @@
+2010-08-30 Alejandro G. Castro <alex at igalia.com>
+
+ Reviewed by Martin Robinson.
+
+ [Gtk] gdk_display_get_core_pointer and gdk_device_get_core_pointer
+ are deprecated
+ https://bugs.webkit.org/show_bug.cgi?id=44787
+
+ We have replaced GtkVersioning.cpp with GtkVersioning.c and
+ created a function (getDefaultGDKPointerDevice) to get the pointer
+ of the window with the new APIs. We added that function to DRT and
+ copyandpaste unit test.
+
+ * GNUmakefile.am:
+
2010-08-30 Martin Robinson <mrobinson at igalia.com>
Reviewed by Xan Lopez.
diff --git a/GNUmakefile.am b/GNUmakefile.am
index ddc5cc7..747125d 100644
--- a/GNUmakefile.am
+++ b/GNUmakefile.am
@@ -695,8 +695,11 @@ Programs_unittests_testkeyevents_CFLAGS = $(webkit_tests_cflags)
Programs_unittests_testkeyevents_LDADD = $(webkit_tests_ldadd)
Programs_unittests_testkeyevents_LDFLAGS = $(webkit_tests_ldflags)
-Programs_unittests_testcopyandpaste_SOURCES = WebKit/gtk/tests/testcopyandpaste.c
-Programs_unittests_testcopyandpaste_CFLAGS = $(webkit_tests_cflags)
+Programs_unittests_testcopyandpaste_SOURCES = WebKit/gtk/tests/testcopyandpaste.c \
+ WebCore/platform/gtk/GtkVersioning.c
+Programs_unittests_testcopyandpaste_CFLAGS = $(webkit_tests_cflags) \
+ -I$(srcdir)/WebCore/platform/gtk \
+ -I$(srcdir)/WebCore
Programs_unittests_testcopyandpaste_LDADD = $(webkit_tests_ldadd)
Programs_unittests_testcopyandpaste_LDFLAGS = $(webkit_tests_ldflags)
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 3db3f0a..39d1e2a 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,24 @@
+2010-08-30 Alejandro G. Castro <alex at igalia.com>
+
+ Reviewed by Martin Robinson.
+
+ [Gtk] gdk_display_get_core_pointer and gdk_device_get_core_pointer
+ are deprecated
+ https://bugs.webkit.org/show_bug.cgi?id=44787
+
+ We have replaced GtkVersioning.cpp with GtkVersioning.c and
+ created a function (getDefaultGDKPointerDevice) to get the pointer
+ of the window with the new APIs. We added that function to DRT and
+ copyandpaste unit test.
+
+ * GNUmakefile.am:
+ * platform/gtk/GtkVersioning.c: Added.
+ (gtk_adjustment_set_value):
+ (gtk_adjustment_configure):
+ (getDefaultGDKPointerDevice):
+ * platform/gtk/GtkVersioning.cpp: Removed.
+ * platform/gtk/GtkVersioning.h:
+
2010-08-30 Darin Adler <darin at apple.com>
Reviewed by Sam Weinig.
diff --git a/WebCore/GNUmakefile.am b/WebCore/GNUmakefile.am
index bc57c66..1e1de03 100644
--- a/WebCore/GNUmakefile.am
+++ b/WebCore/GNUmakefile.am
@@ -2495,7 +2495,7 @@ webcoregtk_sources += \
WebCore/platform/gtk/gtkdrawing.h \
WebCore/platform/gtk/GtkPluginWidget.cpp \
WebCore/platform/gtk/GtkPluginWidget.h \
- WebCore/platform/gtk/GtkVersioning.cpp \
+ WebCore/platform/gtk/GtkVersioning.c \
WebCore/platform/gtk/GtkVersioning.h \
WebCore/platform/gtk/KeyEventGtk.cpp \
WebCore/platform/gtk/KURLGtk.cpp \
diff --git a/WebCore/platform/gtk/GtkVersioning.c b/WebCore/platform/gtk/GtkVersioning.c
new file mode 100644
index 0000000..0871d81
--- /dev/null
+++ b/WebCore/platform/gtk/GtkVersioning.c
@@ -0,0 +1,61 @@
+/*
+ * Copyright (C) 2010 Collabora Ltd.
+ * Copyright (C) 2010 Igalia, S.L.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public License
+ * along with this library; see the file COPYING.LIB. If not, write to
+ * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+ * Boston, MA 02110-1301, USA.
+ */
+
+#include "GtkVersioning.h"
+
+#include <gtk/gtk.h>
+
+#if !GTK_CHECK_VERSION(2, 14, 0)
+void gtk_adjustment_set_value(GtkAdjustment* adjusment, gdouble value)
+{
+ m_adjustment->value = m_currentPos;
+ gtk_adjustment_value_changed(m_adjustment);
+}
+
+void gtk_adjustment_configure(GtkAdjustment* adjustment, gdouble value, gdouble lower, gdouble upper,
+ gdouble stepIncrement, gdouble pageIncrement, gdouble pageSize)
+{
+ g_object_freeze_notify(G_OBJECT(adjustment));
+
+ g_object_set(adjustment,
+ "lower", lower,
+ "upper", upper,
+ "step-increment", stepIncrement,
+ "page-increment", pageIncrement,
+ "page-size", pageSize,
+ NULL);
+
+ g_object_thaw_notify(G_OBJECT(adjustment));
+
+ gtk_adjustment_changed(adjustment);
+ gtk_adjustment_value_changed(adjustment);
+}
+#endif
+
+GdkDevice *getDefaultGDKPointerDevice(GdkWindow* window)
+{
+#ifndef GTK_API_VERSION_2
+ GdkDeviceManager *manager = gdk_display_get_device_manager(gdk_drawable_get_display(window));
+ return gdk_device_manager_get_client_pointer(manager);
+#else
+ return gdk_device_get_core_pointer();
+#endif // GTK_API_VERSION_2
+}
+
diff --git a/WebCore/platform/gtk/GtkVersioning.cpp b/WebCore/platform/gtk/GtkVersioning.cpp
deleted file mode 100644
index e7734a8..0000000
--- a/WebCore/platform/gtk/GtkVersioning.cpp
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (C) 2010 Collabora Ltd.
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public License
- * along with this library; see the file COPYING.LIB. If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- * Boston, MA 02110-1301, USA.
- */
-
-#include "config.h"
-#include "GtkVersioning.h"
-
-#include <gtk/gtk.h>
-
-#if !GTK_CHECK_VERSION(2, 14, 0)
-void gtk_adjustment_set_value(GtkAdjustment* adjusment, gdouble value)
-{
- m_adjustment->value = m_currentPos;
- gtk_adjustment_value_changed(m_adjustment);
-}
-
-void gtk_adjustment_configure(GtkAdjustment* adjustment, gdouble value, gdouble lower, gdouble upper,
- gdouble stepIncrement, gdouble pageIncrement, gdouble pageSize)
-{
- g_object_freeze_notify(G_OBJECT(adjustment));
-
- g_object_set(adjustment,
- "lower", lower,
- "upper", upper,
- "step-increment", stepIncrement,
- "page-increment", pageIncrement,
- "page-size", pageSize,
- NULL);
-
- g_object_thaw_notify(G_OBJECT(adjustment));
-
- gtk_adjustment_changed(adjustment);
- gtk_adjustment_value_changed(adjustment);
-}
-#endif
diff --git a/WebCore/platform/gtk/GtkVersioning.h b/WebCore/platform/gtk/GtkVersioning.h
index 34e6081..6ef8a0f 100644
--- a/WebCore/platform/gtk/GtkVersioning.h
+++ b/WebCore/platform/gtk/GtkVersioning.h
@@ -1,5 +1,6 @@
/*
* Copyright (C) 2010 Collabora Ltd.
+ * Copyright (C) 2010 Igalia, S.L.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
@@ -22,6 +23,8 @@
#include <gtk/gtk.h>
+G_BEGIN_DECLS
+
// Macros to avoid deprecation checking churn
#if !GTK_CHECK_VERSION(2, 21, 2)
#define gdk_visual_get_depth(visual) (visual)->depth
@@ -67,4 +70,8 @@ void gtk_adjustment_configure(GtkAdjustment* adjustment, gdouble value, gdouble
void gtk_adjustment_set_value(GtkAdjustment* adjusment, gdouble value);
#endif // GTK_CHECK_VERSION(2, 14, 0)
+GdkDevice* getDefaultGDKPointerDevice(GdkWindow* window);
+
+G_END_DECLS
+
#endif // GtkVersioning_h
diff --git a/WebKit/gtk/ChangeLog b/WebKit/gtk/ChangeLog
index 9f8a1b3..e58e693 100644
--- a/WebKit/gtk/ChangeLog
+++ b/WebKit/gtk/ChangeLog
@@ -1,3 +1,19 @@
+2010-08-30 Alejandro G. Castro <alex at igalia.com>
+
+ Reviewed by Martin Robinson.
+
+ [Gtk] gdk_display_get_core_pointer and gdk_device_get_core_pointer
+ are deprecated
+ https://bugs.webkit.org/show_bug.cgi?id=44787
+
+ We have replaced GtkVersioning.cpp with GtkVersioning.c and
+ created a function (getDefaultGDKPointerDevice) to get the pointer
+ of the window with the new APIs. We added that function to DRT and
+ copyandpaste unit test.
+
+ * tests/testcopyandpaste.c:
+ (runPasteTestCallback):
+
2010-08-30 Sheriff Bot <webkit.review.bot at gmail.com>
Unreviewed, rolling out r66198.
diff --git a/WebKit/gtk/tests/testcopyandpaste.c b/WebKit/gtk/tests/testcopyandpaste.c
index 58fb764..5e3f5e7 100644
--- a/WebKit/gtk/tests/testcopyandpaste.c
+++ b/WebKit/gtk/tests/testcopyandpaste.c
@@ -25,7 +25,6 @@
#include <JavaScriptCore/JSStringRef.h>
#include <JavaScriptCore/JSContextRef.h>
-
#if GTK_CHECK_VERSION(2, 14, 0)
typedef struct {
@@ -134,8 +133,10 @@ static JSValueRef runPasteTestCallback(JSContextRef context, JSObjectRef functio
event->key.window = gtk_widget_get_window(GTK_WIDGET(currentFixture->webView));
g_object_ref(event->key.window);
#ifndef GTK_API_VERSION_2
- gdk_event_set_device(event, gdk_device_get_associated_device(gdk_display_get_core_pointer(gdk_drawable_get_display(event->key.window))));
+ GdkDeviceManager* manager = gdk_display_get_device_manager(gdk_drawable_get_display(event->key.window));
+ gdk_event_set_device(event, gdk_device_manager_get_client_pointer(manager));
#endif
+
GdkKeymapKey* keys;
gint n_keys;
if (gdk_keymap_get_entries_for_keyval(gdk_keymap_get_default(), event->key.keyval, &keys, &n_keys)) {
diff --git a/WebKitTools/ChangeLog b/WebKitTools/ChangeLog
index 97cdb9f..7d5bfda 100644
--- a/WebKitTools/ChangeLog
+++ b/WebKitTools/ChangeLog
@@ -1,3 +1,22 @@
+2010-08-30 Alejandro G. Castro <alex at igalia.com>
+
+ Reviewed by Martin Robinson.
+
+ [Gtk] gdk_display_get_core_pointer and gdk_device_get_core_pointer
+ are deprecated
+ https://bugs.webkit.org/show_bug.cgi?id=44787
+
+ We have replaced GtkVersioning.cpp with GtkVersioning.c and
+ created a function (getDefaultGDKPointerDevice) to get the pointer
+ of the window with the new APIs. We added that function to DRT and
+ copyandpaste unit test.
+
+ * DumpRenderTree/gtk/EventSender.cpp:
+ (prepareMouseButtonEvent):
+ (mouseMoveToCallback):
+ (keyDownCallback):
+ * GNUmakefile.am:
+
2010-08-30 Zoltan Horvath <zoltan at webkit.org>
Reviewed by Kenneth Rohde Christiansen.
diff --git a/WebKitTools/DumpRenderTree/gtk/EventSender.cpp b/WebKitTools/DumpRenderTree/gtk/EventSender.cpp
index fa3af64..49cd745 100644
--- a/WebKitTools/DumpRenderTree/gtk/EventSender.cpp
+++ b/WebKitTools/DumpRenderTree/gtk/EventSender.cpp
@@ -2,6 +2,7 @@
* Copyright (C) 2007, 2008 Apple Inc. All rights reserved.
* Copyright (C) 2009 Zan Dobersek <zandobersek at gmail.com>
* Copyright (C) 2009 Holger Hans Peter Freyther
+ * Copyright (C) 2010 Igalia S.L.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -33,6 +34,7 @@
#include "DumpRenderTree.h"
+#include <GtkVersioning.h>
#include <JavaScriptCore/JSObjectRef.h>
#include <JavaScriptCore/JSRetainPtr.h>
#include <JavaScriptCore/JSStringRef.h>
@@ -161,7 +163,7 @@ bool prepareMouseButtonEvent(GdkEvent* event, int eventSenderButtonNumber)
event->button.y = lastMousePositionY;
event->button.window = gtk_widget_get_window(GTK_WIDGET(view));
g_object_ref(event->button.window);
- event->button.device = gdk_device_get_core_pointer();
+ event->button.device = getDefaultGDKPointerDevice(event->button.window);
event->button.state = getStateFlags();
event->button.time = GDK_CURRENT_TIME;
event->button.axes = 0;
@@ -285,7 +287,7 @@ static JSValueRef mouseMoveToCallback(JSContextRef context, JSObjectRef function
event->motion.time = GDK_CURRENT_TIME;
event->motion.window = gtk_widget_get_window(GTK_WIDGET(view));
g_object_ref(event->motion.window);
- event->motion.device = gdk_device_get_core_pointer();
+ event->button.device = getDefaultGDKPointerDevice(event->motion.window);
event->motion.state = getStateFlags();
event->motion.axes = 0;
@@ -558,8 +560,9 @@ static JSValueRef keyDownCallback(JSContextRef context, JSObjectRef function, JS
pressEvent->key.window = gtk_widget_get_window(GTK_WIDGET(view));
g_object_ref(pressEvent->key.window);
#ifndef GTK_API_VERSION_2
- gdk_event_set_device(pressEvent, gdk_device_get_associated_device(gdk_display_get_core_pointer(gdk_drawable_get_display(pressEvent->key.window))));
+ gdk_event_set_device(pressEvent, getDefaultGDKPointerDevice(pressEvent->key.window));
#endif
+
// When synthesizing an event, an invalid hardware_keycode value
// can cause it to be badly processed by Gtk+.
GdkKeymapKey* keys;
diff --git a/WebKitTools/GNUmakefile.am b/WebKitTools/GNUmakefile.am
index 33d4614..39df421 100644
--- a/WebKitTools/GNUmakefile.am
+++ b/WebKitTools/GNUmakefile.am
@@ -36,6 +36,7 @@ dumprendertree_cppflags := \
-I$(srcdir)/WebKitTools/DumpRenderTree/cairo \
-I$(srcdir)/WebKitTools/DumpRenderTree/gtk \
-I$(srcdir)/WebKit/gtk \
+ -I$(srcdir)/WebCore/platform/gtk \
-I$(top_builddir)/WebKit/gtk \
-I$(top_builddir)/DerivedSources \
$(global_cppflags) \
@@ -72,7 +73,8 @@ Programs_DumpRenderTree_SOURCES = \
WebKitTools/DumpRenderTree/gtk/GCControllerGtk.cpp \
WebKitTools/DumpRenderTree/gtk/LayoutTestControllerGtk.cpp \
WebKitTools/DumpRenderTree/gtk/PixelDumpSupportGtk.cpp \
- WebKitTools/DumpRenderTree/gtk/WorkQueueItemGtk.cpp
+ WebKitTools/DumpRenderTree/gtk/WorkQueueItemGtk.cpp \
+ WebCore/platform/gtk/GtkVersioning.c
Programs_DumpRenderTree_CXXFLAGS = \
$(global_cxxflags) \
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list