Commit f9a33ab2 authored by Shawn Gallea's avatar Shawn Gallea Committed by Commit Bot

Remove CancelGesture touch location

This is not needed

Merge-With: eureka-internal/472392
Bug: NONE
Test: Locally on device
Change-Id: Ia64527d24c0fc7062cd9da8aa51c00d304d0fd6a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2485277Reviewed-by: default avatarSean Topping <seantopping@chromium.org>
Commit-Queue: Shawn Gallea <sagallea@google.com>
Cr-Commit-Position: refs/heads/master@{#821022}
parent bb685918
......@@ -93,7 +93,7 @@ void CastContentGestureHandler::HandleSideSwipe(
if (gesture_type == GestureType::GO_BACK &&
touch_location.x() < back_horizontal_threshold_) {
DVLOG(1) << "swipe gesture cancelled";
delegate_->CancelGesture(GestureType::GO_BACK, touch_location);
delegate_->CancelGesture(GestureType::GO_BACK);
return;
}
delegate_->ConsumeGesture(gesture_type, base::DoNothing());
......
......@@ -171,8 +171,7 @@ TEST_F(CastContentGestureHandlerTest, VerifyNotFarEnoughRightIsNotBack) {
.WillRepeatedly(Return(true));
EXPECT_CALL(*delegate_, GestureProgress(Eq(GestureType::GO_BACK),
Eq(kOngoingBackGesturePoint1)));
EXPECT_CALL(*delegate_, CancelGesture(Eq(GestureType::GO_BACK),
Eq(kOngoingBackGesturePoint2)));
EXPECT_CALL(*delegate_, CancelGesture(Eq(GestureType::GO_BACK)));
dispatcher_.CanHandleSwipe(CastSideSwipeOrigin::LEFT);
dispatcher_.HandleSideSwipe(CastSideSwipeEvent::BEGIN,
CastSideSwipeOrigin::LEFT, kLeftSidePoint);
......@@ -194,8 +193,7 @@ TEST_F(CastContentGestureHandlerTest, VerifyNotFarEnoughRightAndEndIsNotBack) {
.WillRepeatedly(Return(true));
EXPECT_CALL(*delegate_, GestureProgress(Eq(GestureType::GO_BACK),
Eq(kOngoingBackGesturePoint1)));
EXPECT_CALL(*delegate_, CancelGesture(Eq(GestureType::GO_BACK),
Eq(kOngoingBackGesturePoint2)));
EXPECT_CALL(*delegate_, CancelGesture(Eq(GestureType::GO_BACK)));
dispatcher_.CanHandleSwipe(CastSideSwipeOrigin::LEFT);
dispatcher_.HandleSideSwipe(CastSideSwipeEvent::BEGIN,
CastSideSwipeOrigin::LEFT, kLeftSidePoint);
......
......@@ -113,8 +113,7 @@ class CastContentWindow {
// Called when an in-progress system UI gesture is cancelled (for example
// when the finger is lifted before the completion of the gesture.)
virtual void CancelGesture(GestureType gesture_type,
const gfx::Point& touch_location) {}
virtual void CancelGesture(GestureType gesture_type) {}
// Consume and handle a completed UI gesture. Invokes the callback with a
// boolean indicating whether the gesture was handled or not.
......
......@@ -22,9 +22,7 @@ class MockCastContentWindowDelegate
MOCK_METHOD2(ConsumeGesture,
void(GestureType gesture_type,
base::RepeatingCallback<void(bool)> handled_callback));
MOCK_METHOD2(CancelGesture,
void(GestureType gesture_type,
const gfx::Point& touch_location));
MOCK_METHOD1(CancelGesture, void(GestureType gesture_type));
MOCK_METHOD2(GestureProgress,
void(GestureType gesture_type,
const gfx::Point& touch_location));
......
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