| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // Draws the view for the balloons. | 5 // Draws the view for the balloons. |
| 6 | 6 |
| 7 #ifndef CHROME_BROWSER_UI_GTK_NOTIFICATIONS_BALLOON_VIEW_GTK_H_ | 7 #ifndef CHROME_BROWSER_UI_GTK_NOTIFICATIONS_BALLOON_VIEW_GTK_H_ |
| 8 #define CHROME_BROWSER_UI_GTK_NOTIFICATIONS_BALLOON_VIEW_GTK_H_ | 8 #define CHROME_BROWSER_UI_GTK_NOTIFICATIONS_BALLOON_VIEW_GTK_H_ |
| 9 #pragma once | 9 #pragma once |
| 10 | 10 |
| (...skipping 23 matching lines...) Expand all Loading... |
| 34 } | 34 } |
| 35 | 35 |
| 36 // A balloon view is the UI component for desktop notification toasts. | 36 // A balloon view is the UI component for desktop notification toasts. |
| 37 // It draws a border, and within the border an HTML renderer. | 37 // It draws a border, and within the border an HTML renderer. |
| 38 class BalloonViewImpl : public BalloonView, | 38 class BalloonViewImpl : public BalloonView, |
| 39 public MenuGtk::Delegate, | 39 public MenuGtk::Delegate, |
| 40 public NotificationObserver, | 40 public NotificationObserver, |
| 41 public ui::AnimationDelegate { | 41 public ui::AnimationDelegate { |
| 42 public: | 42 public: |
| 43 explicit BalloonViewImpl(BalloonCollection* collection); | 43 explicit BalloonViewImpl(BalloonCollection* collection); |
| 44 ~BalloonViewImpl(); | 44 virtual ~BalloonViewImpl(); |
| 45 | 45 |
| 46 // BalloonView interface. | 46 // BalloonView interface. |
| 47 virtual void Show(Balloon* balloon); | 47 virtual void Show(Balloon* balloon); |
| 48 virtual void Update(); | 48 virtual void Update(); |
| 49 virtual void RepositionToBalloon(); | 49 virtual void RepositionToBalloon(); |
| 50 virtual void Close(bool by_user); | 50 virtual void Close(bool by_user); |
| 51 virtual gfx::Size GetSize() const; | 51 virtual gfx::Size GetSize() const; |
| 52 virtual BalloonHost* GetHost() const; | 52 virtual BalloonHost* GetHost() const; |
| 53 | 53 |
| 54 // MenuGtk::Delegate interface. | 54 // MenuGtk::Delegate interface. |
| (...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 132 // Is the menu currently showing? | 132 // Is the menu currently showing? |
| 133 bool menu_showing_; | 133 bool menu_showing_; |
| 134 | 134 |
| 135 // Is there a pending system-initiated close? | 135 // Is there a pending system-initiated close? |
| 136 bool pending_close_; | 136 bool pending_close_; |
| 137 | 137 |
| 138 DISALLOW_COPY_AND_ASSIGN(BalloonViewImpl); | 138 DISALLOW_COPY_AND_ASSIGN(BalloonViewImpl); |
| 139 }; | 139 }; |
| 140 | 140 |
| 141 #endif // CHROME_BROWSER_UI_GTK_NOTIFICATIONS_BALLOON_VIEW_GTK_H_ | 141 #endif // CHROME_BROWSER_UI_GTK_NOTIFICATIONS_BALLOON_VIEW_GTK_H_ |
| OLD | NEW |