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

Unified Diff: views/view.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/view.h ('k') | views/view_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: views/view.cc
diff --git a/views/view.cc b/views/view.cc
index a66587eca6c51a77682116a7933d9648cd78bf5a..38854f123ac01549ffbc2294df777085d8159124 100644
--- a/views/view.cc
+++ b/views/view.cc
@@ -801,7 +801,10 @@ bool View::OnMouseDragged(const MouseEvent& event) {
return false;
}
-void View::OnMouseReleased(const MouseEvent& event, bool canceled) {
+void View::OnMouseReleased(const MouseEvent& event) {
+}
+
+void View::OnMouseCaptureLost() {
}
void View::OnMouseMoved(const MouseEvent& event) {
@@ -1557,18 +1560,18 @@ bool View::ProcessMouseDragged(const MouseEvent& event, DragInfo* drag_info) {
return (context_menu_controller != NULL) || possible_drag;
}
-void View::ProcessMouseReleased(const MouseEvent& event, bool canceled) {
- if (!canceled && context_menu_controller_ && event.IsOnlyRightMouseButton()) {
+void View::ProcessMouseReleased(const MouseEvent& event) {
+ if (context_menu_controller_ && event.IsOnlyRightMouseButton()) {
// Assume that if there is a context menu controller we won't be deleted
// from mouse released.
gfx::Point location(event.location());
- OnMouseReleased(event, canceled);
+ OnMouseReleased(event);
if (HitTest(location)) {
ConvertPointToScreen(this, &location);
ShowContextMenu(location, true);
}
} else {
- OnMouseReleased(event, canceled);
+ OnMouseReleased(event);
}
// WARNING: we may have been deleted.
}
« no previous file with comments | « views/view.h ('k') | views/view_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698