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

Side by Side Diff: ash/system/web_notification/web_notification_tray.cc

Issue 10824295: Rid the world of the last of views::Event types: TouchEvent, GestureEvent, MouseWheelEvent, ScrollE… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ash/system/tray/tray_views.cc ('k') | ash/wm/maximize_bubble_controller.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "ash/system/web_notification/web_notification_tray.h" 5 #include "ash/system/web_notification/web_notification_tray.h"
6 6
7 #include "ash/system/status_area_widget.h" 7 #include "ash/system/status_area_widget.h"
8 #include "ash/system/tray/system_tray.h" 8 #include "ash/system/tray/system_tray.h"
9 #include "ash/system/tray/tray_bubble_view.h" 9 #include "ash/system/tray/tray_bubble_view.h"
10 #include "ash/system/tray/tray_constants.h" 10 #include "ash/system/tray/tray_constants.h"
(...skipping 418 matching lines...) Expand 10 before | Expand all | Expand 10 after
429 layout->AddPaddingRow(0, kTrayPopupPaddingBetweenItems); 429 layout->AddPaddingRow(0, kTrayPopupPaddingBetweenItems);
430 } 430 }
431 431
432 // views::View overrides. 432 // views::View overrides.
433 virtual bool OnMousePressed(const ui::MouseEvent& event) OVERRIDE { 433 virtual bool OnMousePressed(const ui::MouseEvent& event) OVERRIDE {
434 tray_->OnClicked(notification_.id); 434 tray_->OnClicked(notification_.id);
435 return true; 435 return true;
436 } 436 }
437 437
438 virtual ui::GestureStatus OnGestureEvent( 438 virtual ui::GestureStatus OnGestureEvent(
439 const views::GestureEvent& event) OVERRIDE { 439 const ui::GestureEvent& event) OVERRIDE {
440 if (event.type() != ui::ET_GESTURE_TAP) 440 if (event.type() != ui::ET_GESTURE_TAP)
441 return ui::GESTURE_STATUS_UNKNOWN; 441 return ui::GESTURE_STATUS_UNKNOWN;
442 tray_->OnClicked(notification_.id); 442 tray_->OnClicked(notification_.id);
443 return ui::GESTURE_STATUS_CONSUMED; 443 return ui::GESTURE_STATUS_CONSUMED;
444 } 444 }
445 445
446 // Overridden from ButtonListener. 446 // Overridden from ButtonListener.
447 virtual void ButtonPressed(views::Button* sender, 447 virtual void ButtonPressed(views::Button* sender,
448 const ui::Event& event) OVERRIDE { 448 const ui::Event& event) OVERRIDE {
449 if (sender == close_button_) 449 if (sender == close_button_)
(...skipping 614 matching lines...) Expand 10 before | Expand all | Expand 10 after
1064 } else if (bubble == notification_bubble()) { 1064 } else if (bubble == notification_bubble()) {
1065 HideNotificationBubble(); 1065 HideNotificationBubble();
1066 } 1066 }
1067 } 1067 }
1068 1068
1069 bool WebNotificationTray::HasNotificationForTest(const std::string& id) const { 1069 bool WebNotificationTray::HasNotificationForTest(const std::string& id) const {
1070 return notification_list_->HasNotification(id); 1070 return notification_list_->HasNotification(id);
1071 } 1071 }
1072 1072
1073 } // namespace ash 1073 } // namespace ash
OLDNEW
« no previous file with comments | « ash/system/tray/tray_views.cc ('k') | ash/wm/maximize_bubble_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698