Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1335)

Unified Diff: content/browser/renderer_host/input/synthetic_gesture.cc

Issue 62443007: Replace old with new synthetic gesture framework. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Forward declare SyntheticGestureController. Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/input/synthetic_gesture.cc
diff --git a/content/browser/renderer_host/input/synthetic_gesture_new.cc b/content/browser/renderer_host/input/synthetic_gesture.cc
similarity index 67%
rename from content/browser/renderer_host/input/synthetic_gesture_new.cc
rename to content/browser/renderer_host/input/synthetic_gesture.cc
index 3812504367cfe3141570d0720aa3f95f152f5371..9b57168dcd1d495d2f40fc2ae6955023dd40eb6b 100644
--- a/content/browser/renderer_host/input/synthetic_gesture_new.cc
+++ b/content/browser/renderer_host/input/synthetic_gesture.cc
@@ -2,40 +2,40 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#include "content/browser/renderer_host/input/synthetic_gesture_new.h"
+#include "content/browser/renderer_host/input/synthetic_gesture.h"
#include "content/browser/renderer_host/input/synthetic_gesture_target.h"
-#include "content/browser/renderer_host/input/synthetic_pinch_gesture_new.h"
-#include "content/browser/renderer_host/input/synthetic_smooth_scroll_gesture_new.h"
+#include "content/browser/renderer_host/input/synthetic_pinch_gesture.h"
+#include "content/browser/renderer_host/input/synthetic_smooth_scroll_gesture.h"
namespace content {
namespace {
template <typename GestureType, typename GestureParamsType>
-static scoped_ptr<SyntheticGestureNew> CreateGesture(
+static scoped_ptr<SyntheticGesture> CreateGesture(
const SyntheticGestureParams& gesture_params) {
- return scoped_ptr<SyntheticGestureNew>(
+ return scoped_ptr<SyntheticGesture>(
new GestureType(*GestureParamsType::Cast(&gesture_params)));
}
} // namespace
-SyntheticGestureNew::SyntheticGestureNew() {}
+SyntheticGesture::SyntheticGesture() {}
-SyntheticGestureNew::~SyntheticGestureNew() {}
+SyntheticGesture::~SyntheticGesture() {}
-scoped_ptr<SyntheticGestureNew> SyntheticGestureNew::Create(
+scoped_ptr<SyntheticGesture> SyntheticGesture::Create(
const SyntheticGestureParams& gesture_params) {
switch (gesture_params.GetGestureType()) {
case SyntheticGestureParams::SMOOTH_SCROLL_GESTURE:
- return CreateGesture<SyntheticSmoothScrollGestureNew,
+ return CreateGesture<SyntheticSmoothScrollGesture,
SyntheticSmoothScrollGestureParams>(gesture_params);
case SyntheticGestureParams::PINCH_GESTURE:
- return CreateGesture<SyntheticPinchGestureNew,
+ return CreateGesture<SyntheticPinchGesture,
kenrb 2013/11/19 15:43:08 I realize this isn't specific to your patch, but I
Dominik Grewe 2013/11/19 17:10:28 How could we check the size of the data? The messa
SyntheticPinchGestureParams>(gesture_params);
}
NOTREACHED() << "Invalid synthetic gesture type";
- return scoped_ptr<SyntheticGestureNew>();
+ return scoped_ptr<SyntheticGesture>();
}
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698