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

Side by Side Diff: content/browser/renderer_host/input/gesture_text_selector.h

Issue 590483002: Check if Button is pressed for changing selection (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Updated as per review and unittests updated Created 6 years, 2 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 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 #ifndef CONTENT_BROWSER_RENDERER_HOST_INPUT_GESTURE_TEXT_SELECTOR_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_INPUT_GESTURE_TEXT_SELECTOR_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_INPUT_GESTURE_TEXT_SELECTOR_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_INPUT_GESTURE_TEXT_SELECTOR_H_
7 7
8 #include "base/gtest_prod_util.h" 8 #include "base/gtest_prod_util.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 virtual bool OnSingleTapUp(const ui::MotionEvent& e) override; 52 virtual bool OnSingleTapUp(const ui::MotionEvent& e) override;
53 virtual bool OnScroll(const ui::MotionEvent& e1, 53 virtual bool OnScroll(const ui::MotionEvent& e1,
54 const ui::MotionEvent& e2, 54 const ui::MotionEvent& e2,
55 float distance_x, 55 float distance_x,
56 float distance_y) override; 56 float distance_y) override;
57 57
58 static bool ShouldStartTextSelection(const ui::MotionEvent& event); 58 static bool ShouldStartTextSelection(const ui::MotionEvent& event);
59 59
60 GestureTextSelectorClient* client_; 60 GestureTextSelectorClient* client_;
61 bool text_selection_triggered_; 61 bool text_selection_triggered_;
62 bool secondary_button_pressed_;
63 int anchor_x_;
jdduke (slow) 2014/10/10 14:37:33 These should be floats.
AviD 2014/10/10 16:06:11 Done.
64 int anchor_y_;
62 scoped_ptr<ui::GestureDetector> gesture_detector_; 65 scoped_ptr<ui::GestureDetector> gesture_detector_;
63 66
64 DISALLOW_COPY_AND_ASSIGN(GestureTextSelector); 67 DISALLOW_COPY_AND_ASSIGN(GestureTextSelector);
65 }; 68 };
66 69
67 } // namespace content 70 } // namespace content
68 71
69 #endif // CONTENT_BROWSER_RENDERER_HOST_INPUT_GESTURE_TEXT_SELECTOR_H_ 72 #endif // CONTENT_BROWSER_RENDERER_HOST_INPUT_GESTURE_TEXT_SELECTOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698