Changeset 196256 in webkit
- Timestamp:
- Feb 8, 2016 10:28:39 AM (8 years ago)
- Location:
- trunk/Source
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r196254 r196256 1 2016-02-08 Commit Queue <commit-queue@webkit.org> 2 3 Unreviewed, rolling out r196253. 4 https://bugs.webkit.org/show_bug.cgi?id=153990 5 6 Caused several crashes in GTK+ bots (Requested by KaL on 7 #webkit). 8 9 Reverted changeset: 10 11 "[GTK] WebKitWebView should send crossing events to the 12 WebProcess" 13 https://bugs.webkit.org/show_bug.cgi?id=153740 14 http://trac.webkit.org/changeset/196253 15 1 16 2016-02-08 Jeremy Jones <jeremyj@apple.com> 2 17 -
trunk/Source/WebCore/page/EventHandler.cpp
r196253 r196256 1883 1883 scrollbar->mouseMoved(platformMouseEvent); // Handle hover effects on platforms that support visual feedback on scrollbar hovering. 1884 1884 #endif 1885 if (onlyUpdateScrollbars) { 1886 updateMouseEventTargetNode(mouseEvent.targetNode(), platformMouseEvent, true); 1885 if (onlyUpdateScrollbars) 1887 1886 return true; 1888 }1889 1887 } 1890 1888 -
trunk/Source/WebKit2/ChangeLog
r196253 r196256 1 2016-02-08 Commit Queue <commit-queue@webkit.org> 2 3 Unreviewed, rolling out r196253. 4 https://bugs.webkit.org/show_bug.cgi?id=153990 5 6 Caused several crashes in GTK+ bots (Requested by KaL on 7 #webkit). 8 9 Reverted changeset: 10 11 "[GTK] WebKitWebView should send crossing events to the 12 WebProcess" 13 https://bugs.webkit.org/show_bug.cgi?id=153740 14 http://trac.webkit.org/changeset/196253 15 1 16 2016-02-08 Carlos Garcia Campos <cgarcia@igalia.com> 2 17 -
trunk/Source/WebKit2/Shared/gtk/WebEventFactory.cpp
r196253 r196256 73 73 74 74 switch (event->type) { 75 case GDK_ENTER_NOTIFY: 76 case GDK_LEAVE_NOTIFY: 77 case GDK_MOTION_NOTIFY: { 75 case GDK_MOTION_NOTIFY: 78 76 button = WebMouseEvent::NoButton; 79 GdkModifierType state; 80 gdk_event_get_state(event, &state); 81 if (state & GDK_BUTTON1_MASK) 77 if (event->motion.state & GDK_BUTTON1_MASK) 82 78 button = WebMouseEvent::LeftButton; 83 else if ( state & GDK_BUTTON2_MASK)79 else if (event->motion.state & GDK_BUTTON2_MASK) 84 80 button = WebMouseEvent::MiddleButton; 85 else if ( state & GDK_BUTTON3_MASK)81 else if (event->motion.state & GDK_BUTTON3_MASK) 86 82 button = WebMouseEvent::RightButton; 87 83 break; 88 }89 84 case GDK_BUTTON_PRESS: 90 85 case GDK_2BUTTON_PRESS: … … 114 109 switch (event->type) { 115 110 case GDK_MOTION_NOTIFY: 116 case GDK_ENTER_NOTIFY:117 case GDK_LEAVE_NOTIFY:118 111 type = WebEvent::MouseMove; 119 112 break; -
trunk/Source/WebKit2/UIProcess/API/gtk/WebKitWebViewBase.cpp
r196253 r196256 359 359 | GDK_SMOOTH_SCROLL_MASK 360 360 | GDK_POINTER_MOTION_MASK 361 | GDK_ENTER_NOTIFY_MASK362 | GDK_LEAVE_NOTIFY_MASK363 361 | GDK_KEY_PRESS_MASK 364 362 | GDK_KEY_RELEASE_MASK … … 833 831 834 832 priv->pageProxy->handleMouseEvent(NativeWebMouseEvent(reinterpret_cast<GdkEvent*>(event), 0 /* currentClickCount */)); 835 836 return FALSE;837 }838 839 static gboolean webkitWebViewBaseCrossingNotifyEvent(GtkWidget* widget, GdkEventCrossing* crosssingEvent)840 {841 WebKitWebViewBase* webViewBase = WEBKIT_WEB_VIEW_BASE(widget);842 WebKitWebViewBasePrivate* priv = webViewBase->priv;843 844 if (priv->authenticationDialog)845 return FALSE;846 847 // In the case of crossing events, it's very important the actual coordinates the WebProcess receives, because once the mouse leaves848 // the web view, the WebProcess won't receive more events until the mouse enters again in the web view. So, if the coordinates of the leave849 // event are not accurate, the WebProcess might not know the mouse left the view. This can happen because of double to integer conversion,850 // if the coordinates of the leave event are for example (25.2, -0.9), the WebProcess will receive (25, 0) and any hit test will succeed851 // because those coordinates are inside the web view.852 GtkAllocation allocation;853 gtk_widget_get_allocation(widget, &allocation);854 double width = allocation.width;855 double height = allocation.height;856 double x = crosssingEvent->x;857 double y = crosssingEvent->y;858 if (x < 0 && x > -1)859 x = -1;860 else if (x >= width && x < width + 1)861 x = width + 1;862 if (y < 0 && y > -1)863 y = -1;864 else if (y >= height && y < height + 1)865 y = height + 1;866 867 GdkEvent* event = reinterpret_cast<GdkEvent*>(crosssingEvent);868 GUniquePtr<GdkEvent> copiedEvent;869 if (x != crosssingEvent->x || y != crosssingEvent->y) {870 copiedEvent.reset(gdk_event_copy(event));871 copiedEvent->crossing.x = x;872 copiedEvent->crossing.y = y;873 }874 875 priv->pageProxy->handleMouseEvent(NativeWebMouseEvent(copiedEvent ? copiedEvent.get() : event, 0 /* currentClickCount */));876 833 877 834 return FALSE; … … 1122 1079 widgetClass->scroll_event = webkitWebViewBaseScrollEvent; 1123 1080 widgetClass->motion_notify_event = webkitWebViewBaseMotionNotifyEvent; 1124 widgetClass->enter_notify_event = webkitWebViewBaseCrossingNotifyEvent;1125 widgetClass->leave_notify_event = webkitWebViewBaseCrossingNotifyEvent;1126 1081 #if ENABLE(TOUCH_EVENTS) 1127 1082 widgetClass->touch_event = webkitWebViewBaseTouchEvent;
Note: See TracChangeset
for help on using the changeset viewer.