Title: [106828] trunk/Source
- Revision
- 106828
- Author
- [email protected]
- Date
- 2012-02-06 11:54:43 -0800 (Mon, 06 Feb 2012)
Log Message
Add a null check for the gdkwindow, that will happen if the window
is not mapped.
Reviewed by Martin Robinson.
* platform/gtk/GtkUtilities.cpp:
(WebCore::convertWidgetPointToScreenPoint):
* WebCoreSupport/ChromeClientGtk.cpp:
(WebKit::ChromeClient::setCursor):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (106827 => 106828)
--- trunk/Source/WebCore/ChangeLog 2012-02-06 19:50:11 UTC (rev 106827)
+++ trunk/Source/WebCore/ChangeLog 2012-02-06 19:54:43 UTC (rev 106828)
@@ -1,3 +1,13 @@
+2012-02-06 Gustavo Noronha Silva <[email protected]>
+
+ Add a null check for the gdkwindow, that will happen if the window
+ is not mapped.
+
+ Reviewed by Martin Robinson.
+
+ * platform/gtk/GtkUtilities.cpp:
+ (WebCore::convertWidgetPointToScreenPoint):
+
2012-02-06 Eugene Girard <[email protected]>
IndexedDB createObjectStore should throw if options arg is invalid
Modified: trunk/Source/WebCore/platform/gtk/GtkUtilities.cpp (106827 => 106828)
--- trunk/Source/WebCore/platform/gtk/GtkUtilities.cpp 2012-02-06 19:50:11 UTC (rev 106827)
+++ trunk/Source/WebCore/platform/gtk/GtkUtilities.cpp 2012-02-06 19:54:43 UTC (rev 106828)
@@ -34,10 +34,15 @@
if (!toplevelWidget || !gtk_widget_is_toplevel(toplevelWidget) || !GTK_IS_WINDOW(toplevelWidget))
return point;
+ GdkWindow* gdkWindow = gtk_widget_get_window(toplevelWidget);
+ if (!gdkWindow)
+ return point;
+
int xInWindow, yInWindow;
gtk_widget_translate_coordinates(widget, toplevelWidget, point.x(), point.y(), &xInWindow, &yInWindow);
+
int windowOriginX, windowOriginY;
- gdk_window_get_origin(gtk_widget_get_window(toplevelWidget), &windowOriginX, &windowOriginY);
+ gdk_window_get_origin(gdkWindow, &windowOriginX, &windowOriginY);
return IntPoint(windowOriginX + xInWindow, windowOriginY + yInWindow);
}
Modified: trunk/Source/WebKit/gtk/ChangeLog (106827 => 106828)
--- trunk/Source/WebKit/gtk/ChangeLog 2012-02-06 19:50:11 UTC (rev 106827)
+++ trunk/Source/WebKit/gtk/ChangeLog 2012-02-06 19:54:43 UTC (rev 106828)
@@ -1,3 +1,13 @@
+2012-02-06 Gustavo Noronha Silva <[email protected]>
+
+ Add a null check for the gdkwindow, that will happen if the window
+ is not mapped.
+
+ Reviewed by Martin Robinson.
+
+ * WebCoreSupport/ChromeClientGtk.cpp:
+ (WebKit::ChromeClient::setCursor):
+
2012-02-06 Martin Robinson <[email protected]>
[GTK] WebKitWebView does a lot of work during size_allocate when not mapped
Modified: trunk/Source/WebKit/gtk/WebCoreSupport/ChromeClientGtk.cpp (106827 => 106828)
--- trunk/Source/WebKit/gtk/WebCoreSupport/ChromeClientGtk.cpp 2012-02-06 19:50:11 UTC (rev 106827)
+++ trunk/Source/WebKit/gtk/WebCoreSupport/ChromeClientGtk.cpp 2012-02-06 19:54:43 UTC (rev 106828)
@@ -829,6 +829,9 @@
// Setting the cursor may be an expensive operation in some backends,
// so don't re-set the cursor if it's already set to the target value.
GdkWindow* window = gtk_widget_get_window(platformPageClient());
+ if (!window)
+ return;
+
GdkCursor* currentCursor = gdk_window_get_cursor(window);
GdkCursor* newCursor = cursor.platformCursor().get();
if (currentCursor != newCursor)
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes