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

Side by Side Diff: ui/events/gesture_detection/gesture_provider.cc

Issue 2519993002: Move kInvalidDisplayID to display_constants.h. (Closed)
Patch Set: Address comments. Created 4 years 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/events/gesture_detection/gesture_provider.h" 5 #include "ui/events/gesture_detection/gesture_provider.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <cmath> 9 #include <cmath>
10 10
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 const gfx::PointF center = bounds.CenterPoint(); 72 const gfx::PointF center = bounds.CenterPoint();
73 return gfx::RectF( 73 return gfx::RectF(
74 center.x() - width / 2.f, center.y() - height / 2.f, width, height); 74 center.x() - width / 2.f, center.y() - height / 2.f, width, height);
75 } 75 }
76 76
77 } // namespace 77 } // namespace
78 78
79 // GestureProvider:::Config 79 // GestureProvider:::Config
80 80
81 GestureProvider::Config::Config() 81 GestureProvider::Config::Config()
82 : display(display::Display::kInvalidDisplayID, gfx::Rect(1, 1)), 82 : display(display::kInvalidDisplayId, gfx::Rect(1, 1)),
83 double_tap_support_for_platform_enabled(true), 83 double_tap_support_for_platform_enabled(true),
84 gesture_begin_end_types_enabled(false), 84 gesture_begin_end_types_enabled(false),
85 min_gesture_bounds_length(0), 85 min_gesture_bounds_length(0),
86 max_gesture_bounds_length(0) {} 86 max_gesture_bounds_length(0) {}
87 87
88 GestureProvider::Config::Config(const Config& other) = default; 88 GestureProvider::Config::Config(const Config& other) = default;
89 89
90 GestureProvider::Config::~Config() { 90 GestureProvider::Config::~Config() {
91 } 91 }
92 92
(...skipping 819 matching lines...) Expand 10 before | Expand all | Expand 10 after
912 // null'ing of the listener until the sequence has ended. 912 // null'ing of the listener until the sequence has ended.
913 if (current_down_event_) 913 if (current_down_event_)
914 return; 914 return;
915 915
916 const bool double_tap_enabled = 916 const bool double_tap_enabled =
917 double_tap_support_for_page_ && double_tap_support_for_platform_; 917 double_tap_support_for_page_ && double_tap_support_for_platform_;
918 gesture_listener_->SetDoubleTapEnabled(double_tap_enabled); 918 gesture_listener_->SetDoubleTapEnabled(double_tap_enabled);
919 } 919 }
920 920
921 } // namespace ui 921 } // namespace ui
OLDNEW
« no previous file with comments | « ui/events/devices/device_data_manager.cc ('k') | ui/message_center/views/desktop_popup_alignment_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698