Index: ui/touch_selection/touch_selection_controller.cc |
diff --git a/ui/touch_selection/touch_selection_controller.cc b/ui/touch_selection/touch_selection_controller.cc |
index ea5db91a766055c25968c6ea1f9eec101dc2fe66..96577df31d24d28fb022089beabb31e2bb672e00 100644 |
--- a/ui/touch_selection/touch_selection_controller.cc |
+++ b/ui/touch_selection/touch_selection_controller.cc |
@@ -80,6 +80,15 @@ void TouchSelectionController::OnSelectionBoundsChanged( |
if (!force_next_update_ && start == start_ && end_ == end) |
return; |
+ // Notify if selection bounds have just been established or dissolved. |
+ if (start.type() != SelectionBound::EMPTY && |
+ start_.type() == SelectionBound::EMPTY) { |
+ client_->OnSelectionEvent(BOUNDS_ESTABLISHED); |
+ } else if (start.type() == SelectionBound::EMPTY && |
+ start_.type() != SelectionBound::EMPTY) { |
+ client_->OnSelectionEvent(BOUNDS_DISSOLVED); |
+ } |
+ |
start_ = start; |
end_ = end; |
start_orientation_ = ToTouchHandleOrientation(start_.type()); |