Commit f3a3cdd7 authored by Thomas Anderson's avatar Thomas Anderson Committed by Commit Bot

Revert "Fix flaky SyntheticMouseEventTest.MouseEventAck"

This reverts commit 4a7a6504.

Reason for revert: The test fails on the Linux dbg testers.
dbg 64:
https://ci.chromium.org/buildbot/chromium.linux/Linux%20Tests%20%28dbg%29%281%29/68703
dbg 32:
https://ci.chromium.org/buildbot/chromium.linux/Linux%20Tests%20%28dbg%29%281%29%2832%29/46433

Original change's description:
> Fix flaky SyntheticMouseEventTest.MouseEventAck
> 
> Devtools was not correctly handling input that is not generated by itself
> and invoking callbacks when the input wasn't actually processed.
> 
> Add a modifier indicating content was injected using the debugger so that
> we can then query for that to determine if we should release the event.
> This is a stop gap solution until we can actually bind callbacks into the
> sending of events and devtools wouldn't need its own queues of callbacks.
> 
> BUG=789869
> 
> Change-Id: I2b56e8ebf4921b48bd4d35dee2226d7cb780cb94
> Reviewed-on: https://chromium-review.googlesource.com/804357
> Commit-Queue: Dave Tapuska <dtapuska@chromium.org>
> Reviewed-by: Pavel Feldman <pfeldman@chromium.org>
> Reviewed-by: Dmitry Gozman <dgozman@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#521454}

TBR=dgozman@chromium.org,lushnikov@chromium.org,pfeldman@chromium.org,dtapuska@chromium.org

Change-Id: I6cdd9e13b0df35dac12ade33b4c1a2e5c49525bc
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 789869
Reviewed-on: https://chromium-review.googlesource.com/807504Reviewed-by: default avatarThomas Anderson <thomasanderson@chromium.org>
Commit-Queue: Thomas Anderson <thomasanderson@chromium.org>
Cr-Commit-Position: refs/heads/master@{#521544}
parent c0004f13
...@@ -582,7 +582,7 @@ IN_PROC_BROWSER_TEST_F(SyntheticKeyEventTest, KeyboardEventAck) { ...@@ -582,7 +582,7 @@ IN_PROC_BROWSER_TEST_F(SyntheticKeyEventTest, KeyboardEventAck) {
EXPECT_EQ(3u, result_ids_.size()); EXPECT_EQ(3u, result_ids_.size());
} }
IN_PROC_BROWSER_TEST_F(SyntheticMouseEventTest, MouseEventAck) { IN_PROC_BROWSER_TEST_F(SyntheticMouseEventTest, DISABLED_MouseEventAck) {
NavigateToURLBlockUntilNavigationsComplete(shell(), GURL("about:blank"), 1); NavigateToURLBlockUntilNavigationsComplete(shell(), GURL("about:blank"), 1);
Attach(); Attach();
ASSERT_TRUE(content::ExecuteScript( ASSERT_TRUE(content::ExecuteScript(
......
...@@ -66,7 +66,7 @@ int GetEventModifiers(int modifiers, ...@@ -66,7 +66,7 @@ int GetEventModifiers(int modifiers,
bool auto_repeat, bool auto_repeat,
bool is_keypad, bool is_keypad,
int location) { int location) {
int result = blink::WebInputEvent::kFromDebugger; int result = 0;
if (auto_repeat) if (auto_repeat)
result |= blink::WebInputEvent::kIsAutoRepeat; result |= blink::WebInputEvent::kIsAutoRepeat;
if (is_keypad) if (is_keypad)
...@@ -293,9 +293,6 @@ void InputHandler::OnInputEvent(const blink::WebInputEvent& event) { ...@@ -293,9 +293,6 @@ void InputHandler::OnInputEvent(const blink::WebInputEvent& event) {
void InputHandler::OnInputEventAck(InputEventAckSource source, void InputHandler::OnInputEventAck(InputEventAckSource source,
InputEventAckState state, InputEventAckState state,
const blink::WebInputEvent& event) { const blink::WebInputEvent& event) {
if ((event.GetModifiers() & blink::WebInputEvent::kFromDebugger) == 0)
return;
if (blink::WebInputEvent::IsKeyboardEventType(event.GetType()) && if (blink::WebInputEvent::IsKeyboardEventType(event.GetType()) &&
!pending_key_callbacks_.empty()) { !pending_key_callbacks_.empty()) {
pending_key_callbacks_.front()->sendSuccess(); pending_key_callbacks_.front()->sendSuccess();
......
...@@ -246,11 +246,6 @@ class WebInputEvent { ...@@ -246,11 +246,6 @@ class WebInputEvent {
// not actual physical movement of the pointer // not actual physical movement of the pointer
kRelativeMotionEvent = 1 << 22, kRelativeMotionEvent = 1 << 22,
// Indication this event was injected by the devtools.
// TODO(dtapuska): Remove this flag once we are able to bind callbacks
// in event sending.
kFromDebugger = 1 << 23,
// The set of non-stateful modifiers that specifically change the // The set of non-stateful modifiers that specifically change the
// interpretation of the key being pressed. For example; IsLeft, // interpretation of the key being pressed. For example; IsLeft,
// IsRight, IsComposing don't change the meaning of the key // IsRight, IsComposing don't change the meaning of the key
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment