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

Unified Diff: views/controls/resize_area.cc

Issue 6685069: Disambiguate OnMouseCaptureLost from OnMouseReleased, etc. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comments, fix tests, cleanup, etc. Created 9 years, 9 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 | « views/controls/resize_area.h ('k') | views/controls/scrollbar/bitmap_scroll_bar.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: views/controls/resize_area.cc
diff --git a/views/controls/resize_area.cc b/views/controls/resize_area.cc
index 0769cf95ab12495aeb0eb1b95540b922c73e7b6c..c04a537561ea9120710a45f0a8da91f14b9dcdea 100644
--- a/views/controls/resize_area.cc
+++ b/views/controls/resize_area.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -70,9 +70,12 @@ bool ResizeArea::OnMouseDragged(const views::MouseEvent& event) {
return true;
}
-void ResizeArea::OnMouseReleased(const views::MouseEvent& event,
- bool canceled) {
- ReportResizeAmount(canceled ? initial_position_ : event.x(), true);
+void ResizeArea::OnMouseReleased(const views::MouseEvent& event) {
+ ReportResizeAmount(event.x(), true);
+}
+
+void ResizeArea::OnMouseCaptureLost() {
+ ReportResizeAmount(initial_position_, true);
}
void ResizeArea::GetAccessibleState(ui::AccessibleViewState* state) {
« no previous file with comments | « views/controls/resize_area.h ('k') | views/controls/scrollbar/bitmap_scroll_bar.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698