Index: chrome/browser/ui/views/profiles/new_avatar_button.cc |
diff --git a/chrome/browser/ui/views/profiles/new_avatar_button.cc b/chrome/browser/ui/views/profiles/new_avatar_button.cc |
index 3902505d01839f1b4be6d4350ccfca162c93ed0d..9126de6a4c53c2c6853fe0640f3efb3a3b07f5d0 100644 |
--- a/chrome/browser/ui/views/profiles/new_avatar_button.cc |
+++ b/chrome/browser/ui/views/profiles/new_avatar_button.cc |
@@ -132,6 +132,17 @@ void NewAvatarButton::OnMouseReleased(const ui::MouseEvent& event) { |
LabelButton::OnMouseReleased(event); |
} |
+void NewAvatarButton::OnGestureEvent(ui::GestureEvent* event) { |
+ // TODO(wjmaclean): The check for ET_GESTURE_LONG_PRESS is done here since |
+ // no other UI button based on CustomButton appears to handle mouse |
+ // right-click. If other cases are identified, it may make sense to move this |
+ // check to CustomButton. |
+ if (event->type() == ui::ET_GESTURE_LONG_PRESS) |
+ NotifyClick(*event); |
+ else |
+ LabelButton::OnGestureEvent(event); |
+} |
+ |
void NewAvatarButton::OnProfileAdded(const base::FilePath& profile_path) { |
Update(); |
} |