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

Side by Side Diff: ui/message_center/views/notification_view.h

Issue 14198004: Scrolls to the notification when focus moves to its buttons. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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 | « ui/message_center/views/message_view.cc ('k') | ui/message_center/views/notification_view.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 #ifndef UI_MESSAGE_CENTER_VIEWS_NOTIFICATION_VIEW_H_ 5 #ifndef UI_MESSAGE_CENTER_VIEWS_NOTIFICATION_VIEW_H_
6 #define UI_MESSAGE_CENTER_VIEWS_NOTIFICATION_VIEW_H_ 6 #define UI_MESSAGE_CENTER_VIEWS_NOTIFICATION_VIEW_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "ui/message_center/message_center_export.h" 10 #include "ui/message_center/message_center_export.h"
(...skipping 17 matching lines...) Expand all
28 static MessageView* Create(const Notification& notification, 28 static MessageView* Create(const Notification& notification,
29 NotificationChangeObserver* observer, 29 NotificationChangeObserver* observer,
30 bool expanded); 30 bool expanded);
31 31
32 virtual ~NotificationView(); 32 virtual ~NotificationView();
33 33
34 // Overridden from views::View: 34 // Overridden from views::View:
35 virtual gfx::Size GetPreferredSize() OVERRIDE; 35 virtual gfx::Size GetPreferredSize() OVERRIDE;
36 virtual int GetHeightForWidth(int width) OVERRIDE; 36 virtual int GetHeightForWidth(int width) OVERRIDE;
37 virtual void Layout() OVERRIDE; 37 virtual void Layout() OVERRIDE;
38 virtual void ScrollRectToVisible(const gfx::Rect& rect) OVERRIDE;
38 39
39 // Overridden from MessageView: 40 // Overridden from MessageView:
40 virtual void ButtonPressed(views::Button* sender, 41 virtual void ButtonPressed(views::Button* sender,
41 const ui::Event& event) OVERRIDE; 42 const ui::Event& event) OVERRIDE;
42 43
43 protected: 44 protected:
44 NotificationView(const Notification& notification, 45 NotificationView(const Notification& notification,
45 NotificationChangeObserver* observer, 46 NotificationChangeObserver* observer,
46 bool expanded); 47 bool expanded);
47 48
(...skipping 11 matching lines...) Expand all
59 views::View* bottom_view_; 60 views::View* bottom_view_;
60 views::View* image_view_; 61 views::View* image_view_;
61 std::vector<views::View*> action_buttons_; 62 std::vector<views::View*> action_buttons_;
62 63
63 DISALLOW_COPY_AND_ASSIGN(NotificationView); 64 DISALLOW_COPY_AND_ASSIGN(NotificationView);
64 }; 65 };
65 66
66 } // namespace message_center 67 } // namespace message_center
67 68
68 #endif // UI_MESSAGE_CENTER_VIEWS_NOTIFICATION_VIEW_H_ 69 #endif // UI_MESSAGE_CENTER_VIEWS_NOTIFICATION_VIEW_H_
OLDNEW
« no previous file with comments | « ui/message_center/views/message_view.cc ('k') | ui/message_center/views/notification_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698