| 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 #ifndef CHROME_BROWSER_UI_COCOA_STATUS_BUBBLE_MAC_H_ | 5 #ifndef CHROME_BROWSER_UI_COCOA_STATUS_BUBBLE_MAC_H_ |
| 6 #define CHROME_BROWSER_UI_COCOA_STATUS_BUBBLE_MAC_H_ | 6 #define CHROME_BROWSER_UI_COCOA_STATUS_BUBBLE_MAC_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #import <Cocoa/Cocoa.h> | 10 #import <Cocoa/Cocoa.h> |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 kBubbleShowingFadeIn, // In a fade-in transition | 29 kBubbleShowingFadeIn, // In a fade-in transition |
| 30 kBubbleShown, // Fully visible | 30 kBubbleShown, // Fully visible |
| 31 kBubbleHidingTimer, // Waiting to fade out | 31 kBubbleHidingTimer, // Waiting to fade out |
| 32 kBubbleHidingFadeOut // In a fade-out transition | 32 kBubbleHidingFadeOut // In a fade-out transition |
| 33 }; | 33 }; |
| 34 | 34 |
| 35 StatusBubbleMac(NSWindow* parent, id delegate); | 35 StatusBubbleMac(NSWindow* parent, id delegate); |
| 36 virtual ~StatusBubbleMac(); | 36 virtual ~StatusBubbleMac(); |
| 37 | 37 |
| 38 // StatusBubble implementation. | 38 // StatusBubble implementation. |
| 39 virtual void SetStatus(const base::string16& status) OVERRIDE; | 39 virtual void SetStatus(const base::string16& status) override; |
| 40 virtual void SetURL(const GURL& url, const std::string& languages) OVERRIDE; | 40 virtual void SetURL(const GURL& url, const std::string& languages) override; |
| 41 virtual void Hide() OVERRIDE; | 41 virtual void Hide() override; |
| 42 virtual void MouseMoved(const gfx::Point& location, | 42 virtual void MouseMoved(const gfx::Point& location, |
| 43 bool left_content) OVERRIDE; | 43 bool left_content) override; |
| 44 virtual void UpdateDownloadShelfVisibility(bool visible) OVERRIDE; | 44 virtual void UpdateDownloadShelfVisibility(bool visible) override; |
| 45 | 45 |
| 46 // Mac-specific method: Update the size and position of the status bubble to | 46 // Mac-specific method: Update the size and position of the status bubble to |
| 47 // match the parent window. Safe to call even when the status bubble does not | 47 // match the parent window. Safe to call even when the status bubble does not |
| 48 // exist. | 48 // exist. |
| 49 void UpdateSizeAndPosition(); | 49 void UpdateSizeAndPosition(); |
| 50 | 50 |
| 51 // Mac-specific method: Change the parent window of the status bubble. Safe to | 51 // Mac-specific method: Change the parent window of the status bubble. Safe to |
| 52 // call even when the status bubble does not exist. | 52 // call even when the status bubble does not exist. |
| 53 void SwitchParentWindow(NSWindow* parent); | 53 void SwitchParentWindow(NSWindow* parent); |
| 54 | 54 |
| (...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 192 @interface NSObject(StatusBubbleDelegate) | 192 @interface NSObject(StatusBubbleDelegate) |
| 193 // Called to query the delegate about the frame StatusBubble should position | 193 // Called to query the delegate about the frame StatusBubble should position |
| 194 // itself in. Frame is returned in the parent window coordinates. | 194 // itself in. Frame is returned in the parent window coordinates. |
| 195 - (NSRect)statusBubbleBaseFrame; | 195 - (NSRect)statusBubbleBaseFrame; |
| 196 | 196 |
| 197 // Called from SetState to notify the delegate of state changes. | 197 // Called from SetState to notify the delegate of state changes. |
| 198 - (void)statusBubbleWillEnterState:(StatusBubbleMac::StatusBubbleState)state; | 198 - (void)statusBubbleWillEnterState:(StatusBubbleMac::StatusBubbleState)state; |
| 199 @end | 199 @end |
| 200 | 200 |
| 201 #endif // CHROME_BROWSER_UI_COCOA_STATUS_BUBBLE_MAC_H_ | 201 #endif // CHROME_BROWSER_UI_COCOA_STATUS_BUBBLE_MAC_H_ |
| OLD | NEW |