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

Unified Diff: ui/events/gestures/gesture_recognizer_impl.cc

Issue 328733003: Fix slop region boundary handling. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix gn build. Created 6 years, 6 months 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
« no previous file with comments | « ui/events/events.gyp ('k') | ui/events/gestures/unified_gesture_detector_enabled.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/events/gestures/gesture_recognizer_impl.cc
diff --git a/ui/events/gestures/gesture_recognizer_impl.cc b/ui/events/gestures/gesture_recognizer_impl.cc
index 6ec5ccf96f1932ea09af8cada291058428dcb528..e145334454b01ec5df3286a03f6b25ef947be061 100644
--- a/ui/events/gestures/gesture_recognizer_impl.cc
+++ b/ui/events/gestures/gesture_recognizer_impl.cc
@@ -18,6 +18,7 @@
#include "ui/events/gestures/gesture_configuration.h"
#include "ui/events/gestures/gesture_sequence.h"
#include "ui/events/gestures/gesture_types.h"
+#include "ui/events/gestures/unified_gesture_detector_enabled.h"
namespace ui {
@@ -69,28 +70,7 @@ GestureProviderAura* CreateGestureProvider(GestureProviderAuraClient* client) {
// GestureRecognizerImpl, public:
GestureRecognizerImpl::GestureRecognizerImpl() {
- // Default to not using the unified gesture detector.
- const CommandLine& command_line = *CommandLine::ForCurrentProcess();
- const std::string unified_gd_enabled_switch =
- command_line.HasSwitch(switches::kUnifiedGestureDetector) ?
- command_line.GetSwitchValueASCII(switches::kUnifiedGestureDetector) :
- switches::kUnifiedGestureDetectorAuto;
-
- const bool kUseUnifiedGestureDetectorByDefault = false;
- if (unified_gd_enabled_switch.empty() ||
- unified_gd_enabled_switch == switches::kUnifiedGestureDetectorEnabled) {
- use_unified_gesture_detector_ = true;
- } else if (unified_gd_enabled_switch ==
- switches::kUnifiedGestureDetectorDisabled) {
- use_unified_gesture_detector_ = false;
- } else if (unified_gd_enabled_switch ==
- switches::kUnifiedGestureDetectorAuto) {
- use_unified_gesture_detector_ = kUseUnifiedGestureDetectorByDefault;
- } else {
- LOG(ERROR) << "Invalid --unified-gesture-detector option: "
- << unified_gd_enabled_switch;
- use_unified_gesture_detector_ = false;
- }
+ use_unified_gesture_detector_ = IsUnifiedGestureDetectorEnabled();
}
GestureRecognizerImpl::~GestureRecognizerImpl() {
« no previous file with comments | « ui/events/events.gyp ('k') | ui/events/gestures/unified_gesture_detector_enabled.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698