OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 CHROME_BROWSER_GTK_NOTIFICATIONS_NOTIFICATION_OPTIONS_MENU_MODEL_H_ | 5 #ifndef CHROME_BROWSER_GTK_NOTIFICATIONS_NOTIFICATION_OPTIONS_MENU_MODEL_H_ |
6 #define CHROME_BROWSER_GTK_NOTIFICATIONS_NOTIFICATION_OPTIONS_MENU_MODEL_H_ | 6 #define CHROME_BROWSER_GTK_NOTIFICATIONS_NOTIFICATION_OPTIONS_MENU_MODEL_H_ |
7 | 7 |
8 #include "app/menus/menu_model.h" | 8 #include "app/menus/menu_model.h" |
9 | 9 |
10 class Balloon; | 10 class Balloon; |
11 | 11 |
12 // Model for the options menu on the notification balloon. | 12 // Model for the options menu on the notification balloon. |
13 class NotificationOptionsMenuModel : public menus::MenuModel { | 13 class NotificationOptionsMenuModel : public menus::MenuModel { |
14 public: | 14 public: |
15 explicit NotificationOptionsMenuModel(Balloon* balloon); | 15 explicit NotificationOptionsMenuModel(Balloon* balloon); |
16 ~NotificationOptionsMenuModel(); | 16 ~NotificationOptionsMenuModel(); |
17 | 17 |
18 // menus::MenuModel methods. | 18 // menus::MenuModel methods. |
19 virtual bool HasIcons() const; | 19 virtual bool HasIcons() const; |
20 virtual int GetItemCount() const; | 20 virtual int GetItemCount() const; |
21 virtual ItemType GetTypeAt(int index) const; | 21 virtual ItemType GetTypeAt(int index) const; |
22 virtual int GetCommandIdAt(int index) const; | 22 virtual int GetCommandIdAt(int index) const; |
23 virtual string16 GetLabelAt(int index) const; | 23 virtual string16 GetLabelAt(int index) const; |
24 virtual bool IsLabelDynamicAt(int index) const; | 24 virtual bool IsLabelDynamicAt(int index) const; |
25 virtual bool GetAcceleratorAt(int index, | 25 virtual bool GetAcceleratorAt(int index, |
26 menus::Accelerator* accelerator) const; | 26 menus::Accelerator* accelerator) const; |
27 virtual bool IsItemCheckedAt(int index) const; | 27 virtual bool IsItemCheckedAt(int index) const; |
28 virtual int GetGroupIdAt(int index) const; | 28 virtual int GetGroupIdAt(int index) const; |
29 virtual bool GetIconAt(int index, SkBitmap* icon) const; | 29 virtual bool GetIconAt(int index, SkBitmap* icon) const; |
| 30 virtual menus::ButtonMenuItemModel* GetButtonMenuItemAt(int index) const; |
30 virtual bool IsEnabledAt(int index) const; | 31 virtual bool IsEnabledAt(int index) const; |
31 virtual MenuModel* GetSubmenuModelAt(int index) const; | 32 virtual MenuModel* GetSubmenuModelAt(int index) const; |
32 virtual void HighlightChangedTo(int index); | 33 virtual void HighlightChangedTo(int index); |
33 virtual void ActivatedAt(int index); | 34 virtual void ActivatedAt(int index); |
34 | 35 |
35 private: | 36 private: |
36 // Non-owned pointer to the balloon involved. | 37 // Non-owned pointer to the balloon involved. |
37 Balloon* balloon_; | 38 Balloon* balloon_; |
38 | 39 |
39 DISALLOW_COPY_AND_ASSIGN(NotificationOptionsMenuModel); | 40 DISALLOW_COPY_AND_ASSIGN(NotificationOptionsMenuModel); |
40 }; | 41 }; |
41 | 42 |
42 #endif // CHROME_BROWSER_GTK_NOTIFICATIONS_NOTIFICATION_OPTIONS_MENU_MODEL_H_ | 43 #endif // CHROME_BROWSER_GTK_NOTIFICATIONS_NOTIFICATION_OPTIONS_MENU_MODEL_H_ |
OLD | NEW |