Skip to content

Commit

Permalink
Merge r221075, r221260 - [WPE] Some event handlers not working.
Browse files Browse the repository at this point in the history
https://bugs.webkit.org/show_bug.cgi?id=175864

Reviewed by Michael Catanzaro.

Source/WebCore:

Share the EventHandler implementation with the GTK port and add ifdefs where needed.

Covered by existing tests.

* PlatformGTK.cmake:
* PlatformWPE.cmake:
* page/wpe/EventHandlerWPE.cpp: Removed.
* platform/glib/EventHandlerGlib.cpp: Renamed from Source/WebCore/page/gtk/EventHandlerGtk.cpp.
(WebCore::EventHandler::shouldTurnVerticalTicksIntoHorizontal const):

LayoutTests:

Remove expected failures for tests that now pass, add new expectation
for a test that is failing also on GTK+ and rebaseline a test with
the same expected result than on GTK+.

* platform/wpe/TestExpectations:
* platform/wpe/fast/events/focus-label-legend-elements-with-tab-expected.txt: Added.
  • Loading branch information
clopez authored and carlosgcampos committed Oct 17, 2017
1 parent c25dd2f commit c54d555
Show file tree
Hide file tree
Showing 8 changed files with 97 additions and 129 deletions.
14 changes: 14 additions & 0 deletions LayoutTests/ChangeLog
@@ -1,3 +1,17 @@
2017-08-23 Carlos Alberto Lopez Perez <clopez@igalia.com>

[WPE] Some event handlers not working.
https://bugs.webkit.org/show_bug.cgi?id=175864

Reviewed by Michael Catanzaro.

Remove expected failures for tests that now pass, add new expectation
for a test that is failing also on GTK+ and rebaseline a test with
the same expected result than on GTK+.

* platform/wpe/TestExpectations:
* platform/wpe/fast/events/focus-label-legend-elements-with-tab-expected.txt: Added.

2017-10-13 Brent Fulgham <bfulgham@apple.com>

Protect FrameView during style calculations
Expand Down
17 changes: 2 additions & 15 deletions LayoutTests/platform/wpe/TestExpectations
Expand Up @@ -382,7 +382,6 @@ fast/events/wheelevent-direction-inverted-from-device.html
# The tests below need gardening after the EventSenderWPE has been added.
# Most of them are probably failing because of missing support of event related
# features in WPE.
webkit.org/b/173419 fast/events/autoscroll-in-overflow-hidden-html.html [ Failure ]
webkit.org/b/173419 fast/events/autoscroll-in-textarea.html [ Failure ]
webkit.org/b/173419 fast/events/autoscroll-in-textfield.html [ Failure ]
webkit.org/b/173419 fast/events/autoscroll-nonscrollable-iframe-in-scrollable-div.html [ Failure ]
Expand All @@ -404,22 +403,15 @@ webkit.org/b/173419 fast/events/input-events-insert-by-drop.html [ Failure ]
webkit.org/b/173419 fast/events/input-events-paste-data.html [ Failure ]
webkit.org/b/173419 fast/events/input-events-paste-rich-datatransfer.html [ Failure ]
webkit.org/b/173419 fast/events/js-keyboard-event-creation.html [ Failure ]
webkit.org/b/173419 fast/events/keydown-1.html [ Failure ]
webkit.org/b/173419 fast/events/keydown-numpad-keys.html [ Failure ]
webkit.org/b/173419 fast/events/mouse-cursor-image-set.html [ Failure ]
webkit.org/b/173419 fast/events/mouse-drag-from-frame-to-other-frame.html [ Failure ]
webkit.org/b/173419 fast/events/mouse-drag-from-frame.html [ Failure ]
webkit.org/b/173419 fast/events/mouseenterleave-on-subframe.html [ Failure ]
webkit.org/b/173419 fast/events/mouseover-button.html [ Failure ]
webkit.org/b/173419 fast/events/mouseover-mouseout.html [ Failure ]
webkit.org/b/173419 fast/events/mouseover-mouseout2.html [ Failure ]
webkit.org/b/173419 fast/events/mouseup-from-button2.html [ Failure ]
webkit.org/b/173419 fast/events/no-scroll-on-input-text-selection.html [ Failure ]
webkit.org/b/173419 fast/events/node-event-anchor-lock.html [ Failure ]
webkit.org/b/173419 fast/events/offsetX-offsetY.html [ Failure ]
webkit.org/b/173419 fast/events/onchange-range-slider.html [ Failure ]
webkit.org/b/173419 fast/events/option-tab.html [ Failure ]
webkit.org/b/173419 fast/events/page-scaled-mouse-click-iframe.html [ Failure ]
webkit.org/b/173419 fast/events/platform-wheelevent-in-scrolling-div.html [ Failure ]
webkit.org/b/173419 fast/events/platform-wheelevent-paging-x-in-non-scrolling-div.html [ Failure ]
webkit.org/b/173419 fast/events/platform-wheelevent-paging-x-in-non-scrolling-page.html [ Failure ]
Expand Down Expand Up @@ -453,32 +445,27 @@ webkit.org/b/173419 fast/events/autoscroll-main-document.html [ Timeout ]
webkit.org/b/173419 fast/events/autoscroll-should-not-stop-on-keypress.html [ Timeout ]
webkit.org/b/173419 fast/events/autoscroll-when-zoomed.html [ Timeout ]
webkit.org/b/173419 fast/events/before-input-prevent-insert-replacement.html [ Timeout ]
webkit.org/b/173419 fast/events/can-click-element-on-page-with-active-pseudo-class-and-search-field.html [ Timeout ]
webkit.org/b/173419 fast/events/clipboard-dataTransferItemList.html [ Timeout ]
webkit.org/b/173419 fast/events/drag-dataTransferItemList.html [ Timeout ]
webkit.org/b/173419 fast/events/event-view-toString.html [ Timeout ]
webkit.org/b/173419 fast/events/frame-detached-in-mousedown.html [ Timeout ]
webkit.org/b/173419 fast/events/iframe-onmousemove.html [ Timeout ]
webkit.org/b/173419 fast/events/input-event-insert-replacement.html [ Timeout ]
webkit.org/b/173419 fast/events/mouse-force-changed.html [ Timeout ]
webkit.org/b/173419 fast/events/mouse-force-down.html [ Timeout ]
webkit.org/b/173419 fast/events/mouse-force-up.html [ Timeout ]
webkit.org/b/173419 fast/events/mouse-moved-remove-frame-crash.html [ Timeout ]
webkit.org/b/173419 fast/events/page-visibility-iframe-delete-test.html [ Timeout ]
webkit.org/b/173419 fast/events/page-visibility-iframe-move-test.html [ Timeout ]
webkit.org/b/173419 fast/events/page-visibility-iframe-propagation-test.html [ Timeout ]
webkit.org/b/173419 fast/events/page-visibility-onvisibilitychange.html [ Timeout ]
webkit.org/b/173419 fast/events/page-visibility-transition-test.html [ Timeout ]
webkit.org/b/173419 fast/events/popup-blocking-click-in-iframe.html [ Timeout ]
webkit.org/b/173419 fast/events/scroll-after-click-on-tab-index.html [ Timeout ]
webkit.org/b/173419 fast/events/standalone-image-drag-to-editable.html [ Timeout ]
webkit.org/b/173419 fast/events/touch/emulated-touch-iframe.html [ Timeout ]
webkit.org/b/173419 fast/events/touch/multi-touch-grouped-targets.html [ Timeout ]
webkit.org/b/173419 fast/events/touch/multi-touch-inside-nested-iframes.html [ Timeout ]
webkit.org/b/173419 fast/events/touch/page-scaled-touch-gesture-click.html [ Timeout ]
webkit.org/b/173419 fast/events/touch/touch-target-limited.html [ Timeout ]
webkit.org/b/173419 fast/events/touch/touch-target.html [ Timeout ]
webkit.org/b/173419 fast/events/wheel-event-destroys-frame.html [ Timeout ]

webkit.org/b/173411 fast/events/touch/frame-hover-update.html [ Failure ]

fast/events/ios [ Skip ]
fast/events/touch/ios [ Skip ]
Expand Down
@@ -0,0 +1,19 @@
Tests for moving focus by pressing tab key across label and legend elements.
To manually test, press tab key seven times then shift+tab six times.
It should traverse focusable elements in the ascending order from 1 to 7 and then in the descending order back to 1.


1. An input element inside a non-focusable label element
2. A label element with an input element
3. An input elment inside a focusable label element
4. A label element with just text
5. A fieldset element with tabindex
6. A focusable legend element inside a fieldset element
7. An input element inside a fieldset element
6. A focusable legend element inside a fieldset element
5. A fieldset element with tabindex
4. A label element with just text
3. An input elment inside a focusable label element
2. A label element with an input element
1. An input element inside a non-focusable label element

42 changes: 42 additions & 0 deletions Source/WebCore/ChangeLog
@@ -1,3 +1,45 @@
2017-08-28 Carlos Alberto Lopez Perez <clopez@igalia.com>

[GTK] [WPE] Rename EventHandlerGlib to EventHandlerGLib
https://bugs.webkit.org/show_bug.cgi?id=175864

Unreviewed cosmetic follow-up patch after r221075.

No new tests. No change in behavior.

* PlatformGTK.cmake:
* PlatformWPE.cmake:
* platform/glib/EventHandlerGLib.cpp: Renamed from Source/WebCore/platform/glib/EventHandlerGlib.cpp.
(WebCore::EventHandler::tabsToAllFormControls const):
(WebCore::EventHandler::focusDocumentView):
(WebCore::EventHandler::passWidgetMouseDownEventToWidget):
(WebCore::EventHandler::passMouseDownEventToWidget):
(WebCore::EventHandler::eventActivatedView const):
(WebCore::EventHandler::widgetDidHandleWheelEvent):
(WebCore::EventHandler::createDraggingDataTransfer const):
(WebCore::EventHandler::passMousePressEventToSubframe):
(WebCore::EventHandler::passMouseMoveEventToSubframe):
(WebCore::EventHandler::passMouseReleaseEventToSubframe):
(WebCore::EventHandler::accessKeyModifiers):
(WebCore::EventHandler::shouldTurnVerticalTicksIntoHorizontal const):

2017-08-23 Carlos Alberto Lopez Perez <clopez@igalia.com>

[WPE] Some event handlers not working.
https://bugs.webkit.org/show_bug.cgi?id=175864

Reviewed by Michael Catanzaro.

Share the EventHandler implementation with the GTK port and add ifdefs where needed.

Covered by existing tests.

* PlatformGTK.cmake:
* PlatformWPE.cmake:
* page/wpe/EventHandlerWPE.cpp: Removed.
* platform/glib/EventHandlerGlib.cpp: Renamed from Source/WebCore/page/gtk/EventHandlerGtk.cpp.
(WebCore::EventHandler::shouldTurnVerticalTicksIntoHorizontal const):

2017-10-16 Maureen Daum <mdaum@apple.com>

If an origin doesn't have databases in the Databases table we should still remove its information from disk in DatabaseTracker::deleteOrigin()
Expand Down
3 changes: 2 additions & 1 deletion Source/WebCore/PlatformGTK.cmake
Expand Up @@ -154,7 +154,8 @@ list(APPEND WebCorePlatformGTK_SOURCES
editing/gtk/EditorGtk.cpp

page/gtk/DragControllerGtk.cpp
page/gtk/EventHandlerGtk.cpp

platform/glib/EventHandlerGLib.cpp

platform/graphics/PlatformDisplay.cpp

Expand Down
2 changes: 1 addition & 1 deletion Source/WebCore/PlatformWPE.cmake
Expand Up @@ -135,7 +135,7 @@ list(APPEND WebCore_SOURCES
list(APPEND WebCorePlatformWPE_SOURCES
editing/wpe/EditorWPE.cpp

page/wpe/EventHandlerWPE.cpp
platform/glib/EventHandlerGLib.cpp

platform/graphics/egl/GLContextEGLWPE.cpp

Expand Down
108 changes: 0 additions & 108 deletions Source/WebCore/page/wpe/EventHandlerWPE.cpp

This file was deleted.

@@ -1,5 +1,6 @@
/*
* Copyright (C) 2006 Zack Rusin <zack@kde.org>
* Copyright (C) 2014-2017 Igalia S.L.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
Expand All @@ -26,8 +27,6 @@
#include "config.h"
#include "EventHandler.h"

#include "DataTransfer.h"
#include "FloatPoint.h"
#include "FocusController.h"
#include "Frame.h"
#include "FrameView.h"
Expand All @@ -38,7 +37,14 @@
#include "PlatformKeyboardEvent.h"
#include "PlatformWheelEvent.h"
#include "RenderWidget.h"

#if ENABLE(DRAG_SUPPORT)
#include "DataTransfer.h"
#endif

#if PLATFORM(GTK)
#include "Scrollbar.h"
#endif

namespace WebCore {

Expand Down Expand Up @@ -80,8 +86,8 @@ bool EventHandler::passMouseDownEventToWidget(Widget*)

bool EventHandler::eventActivatedView(const PlatformMouseEvent&) const
{
//GTK+ activation is not necessarily tied to mouse events, so it may
//not make sense to implement this
// GTK+ activation is not necessarily tied to mouse events, so it may
// not make sense to implement this

notImplemented();
return false;
Expand Down Expand Up @@ -133,11 +139,18 @@ OptionSet<PlatformEvent::Modifier> EventHandler::accessKeyModifiers()
// for styled scrollbars.
bool EventHandler::shouldTurnVerticalTicksIntoHorizontal(const HitTestResult& result, const PlatformWheelEvent& event) const
{
#if PLATFORM(GTK)
FrameView* view = m_frame.view();
Scrollbar* scrollbar = view ? view->scrollbarAtPoint(event.position()) : nullptr;
if (!scrollbar)
scrollbar = result.scrollbar();
return scrollbar && scrollbar->orientation() == HorizontalScrollbar;
#else
UNUSED_PARAM(result);
UNUSED_PARAM(event);
notImplemented();
return false;
#endif
}

}

0 comments on commit c54d555

Please sign in to comment.