| OLD | NEW |
| 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_TOUCH_SELECTION_CONTROLLER_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_INPUT_TOUCH_SELECTION_CONTROLLER_H_ |
| 6 #define CONTENT_BROWSER_RENDERER_HOST_INPUT_TOUCH_SELECTION_CONTROLLER_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_INPUT_TOUCH_SELECTION_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include "cc/output/viewport_selection_bound.h" | 8 #include "cc/output/viewport_selection_bound.h" |
| 9 #include "content/browser/renderer_host/input/selection_event_type.h" | 9 #include "content/browser/renderer_host/input/selection_event_type.h" |
| 10 #include "content/browser/renderer_host/input/touch_handle.h" | 10 #include "content/browser/renderer_host/input/touch_handle.h" |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 void OnTapEvent(); | 62 void OnTapEvent(); |
| 63 | 63 |
| 64 // To be called before forwarding a longpress event. This allows automatically | 64 // To be called before forwarding a longpress event. This allows automatically |
| 65 // showing the selection or insertion handles from subsequent bounds changes. | 65 // showing the selection or insertion handles from subsequent bounds changes. |
| 66 void OnLongPressEvent(); | 66 void OnLongPressEvent(); |
| 67 | 67 |
| 68 // Hide the handles and suppress bounds updates until the next explicit | 68 // Hide the handles and suppress bounds updates until the next explicit |
| 69 // showing allowance. | 69 // showing allowance. |
| 70 void HideAndDisallowShowingAutomatically(); | 70 void HideAndDisallowShowingAutomatically(); |
| 71 | 71 |
| 72 // Override the handle visibility according to |hidden|. | |
| 73 void SetTemporarilyHidden(bool hidden); | |
| 74 | |
| 75 // To be called when the editability of the focused region changes. | 72 // To be called when the editability of the focused region changes. |
| 76 void OnSelectionEditable(bool editable); | 73 void OnSelectionEditable(bool editable); |
| 77 | 74 |
| 78 // To be called when the contents of the focused region changes. | 75 // To be called when the contents of the focused region changes. |
| 79 void OnSelectionEmpty(bool empty); | 76 void OnSelectionEmpty(bool empty); |
| 80 | 77 |
| 81 // Ticks an active animation, as requested to the client by |SetNeedsAnimate|. | 78 // Ticks an active animation, as requested to the client by |SetNeedsAnimate|. |
| 82 // Returns true if an animation is active and requires further ticking. | 79 // Returns true if an animation is active and requires further ticking. |
| 83 bool Animate(base::TimeTicks animate_time); | 80 bool Animate(base::TimeTicks animate_time); |
| 84 | 81 |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 bool selection_editable_; | 138 bool selection_editable_; |
| 142 | 139 |
| 143 bool temporarily_hidden_; | 140 bool temporarily_hidden_; |
| 144 | 141 |
| 145 DISALLOW_COPY_AND_ASSIGN(TouchSelectionController); | 142 DISALLOW_COPY_AND_ASSIGN(TouchSelectionController); |
| 146 }; | 143 }; |
| 147 | 144 |
| 148 } // namespace content | 145 } // namespace content |
| 149 | 146 |
| 150 #endif // CONTENT_BROWSER_RENDERER_HOST_INPUT_TOUCH_SELECTION_CONTROLLER_H_ | 147 #endif // CONTENT_BROWSER_RENDERER_HOST_INPUT_TOUCH_SELECTION_CONTROLLER_H_ |
| OLD | NEW |