| OLD | NEW |
| 1 // Copyright (c) 2010 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 #ifndef CHROME_BROWSER_UI_COCOA_NOTIFICATIONS_BALLOON_VIEW_HOST_MAC_H_ | 5 #ifndef CHROME_BROWSER_UI_COCOA_NOTIFICATIONS_BALLOON_VIEW_HOST_MAC_H_ |
| 6 #define CHROME_BROWSER_UI_COCOA_NOTIFICATIONS_BALLOON_VIEW_HOST_MAC_H_ | 6 #define CHROME_BROWSER_UI_COCOA_NOTIFICATIONS_BALLOON_VIEW_HOST_MAC_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "chrome/browser/notifications/balloon_host.h" | 9 #include "chrome/browser/notifications/balloon_host.h" |
| 10 | 10 |
| 11 class RenderWidgetHostView; | |
| 12 class RenderWidgetHostViewMac; | |
| 13 | |
| 14 // BalloonViewHost class is a delegate to the renderer host for the HTML | 11 // BalloonViewHost class is a delegate to the renderer host for the HTML |
| 15 // notification. When initialized it creates a new RenderViewHost and loads | 12 // notification. When initialized it creates a new RenderViewHost and loads |
| 16 // the contents of the toast into it. It also handles links within the toast, | 13 // the contents of the toast into it. It also handles links within the toast, |
| 17 // loading them into a new tab. | 14 // loading them into a new tab. |
| 18 class BalloonViewHost : public BalloonHost { | 15 class BalloonViewHost : public BalloonHost { |
| 19 public: | 16 public: |
| 20 explicit BalloonViewHost(Balloon* balloon); | 17 explicit BalloonViewHost(Balloon* balloon); |
| 21 | 18 |
| 22 virtual ~BalloonViewHost(); | 19 virtual ~BalloonViewHost(); |
| 23 | 20 |
| 24 // Changes the size of the balloon. | 21 // Changes the size of the balloon. |
| 25 void UpdateActualSize(const gfx::Size& new_size); | 22 void UpdateActualSize(const gfx::Size& new_size); |
| 26 | 23 |
| 27 // Accessors. | 24 // Accessors. |
| 28 gfx::NativeView native_view() const; | 25 gfx::NativeView native_view() const; |
| 29 | 26 |
| 30 private: | 27 private: |
| 31 DISALLOW_COPY_AND_ASSIGN(BalloonViewHost); | 28 DISALLOW_COPY_AND_ASSIGN(BalloonViewHost); |
| 32 }; | 29 }; |
| 33 | 30 |
| 34 #endif // CHROME_BROWSER_UI_COCOA_NOTIFICATIONS_BALLOON_VIEW_HOST_MAC_H_ | 31 #endif // CHROME_BROWSER_UI_COCOA_NOTIFICATIONS_BALLOON_VIEW_HOST_MAC_H_ |
| OLD | NEW |