Index: chrome/browser/ui/cocoa/fullscreen_exit_bubble_controller.h |
diff --git a/chrome/browser/ui/cocoa/fullscreen_exit_bubble_controller.h b/chrome/browser/ui/cocoa/fullscreen_exit_bubble_controller.h |
index 07dfc1a785e313c9954beacdcc7c4c74aab04b3b..0e9325aa126692686b1304170d77e6f0699c3399 100644 |
--- a/chrome/browser/ui/cocoa/fullscreen_exit_bubble_controller.h |
+++ b/chrome/browser/ui/cocoa/fullscreen_exit_bubble_controller.h |
@@ -7,23 +7,35 @@ |
#import "base/mac/cocoa_protocols.h" |
#include "base/memory/scoped_nsobject.h" |
#include "googleurl/src/gurl.h" |
+#import "third_party/GTM/AppKit/GTMUILocalizerAndLayoutTweaker.h" |
Scott Hess - ex-Googler
2011/10/10 23:19:50
Can this #import be moved into the .mm file by usi
jeremya
2011/10/11 05:28:48
Done.
|
@class AnimatableView; |
class TabContentsWrapper; |
@class BrowserWindowController; |
class Browser; |
+namespace fullscreen_exit_bubble { |
+const int kBubbleOffsetY = 10; |
+} // namespace fullscreen_exit_bubble |
+ |
// The FullscreenExitBubbleController manages the bubble that tells the user |
// how to escape fullscreen mode. The bubble only appears when a tab requests |
// fullscreen mode via webkitRequestFullScreen(). |
@interface FullscreenExitBubbleController : |
- NSViewController<NSTextViewDelegate, NSAnimationDelegate> { |
+ NSWindowController<NSTextViewDelegate, NSAnimationDelegate> { |
@private |
BrowserWindowController* owner_; // weak |
Browser* browser_; // weak |
+ GURL url_; |
+ BOOL show_buttons_; |
@protected |
IBOutlet NSTextField* exitLabelPlaceholder_; |
+ IBOutlet NSTextField* siteInfoLabel_; |
+ IBOutlet NSButton* allowButton_; |
+ IBOutlet NSButton* denyButton_; |
+ IBOutlet InfoBubbleView* bubble_; |
+ IBOutlet GTMUILocalizerAndLayoutTweaker* tweaker_; |
// Text fields don't work as well with embedded links as text views, but |
// text views cannot conveniently be created in IB. The xib file contains |
@@ -35,7 +47,15 @@ class Browser; |
scoped_nsobject<NSAnimation> hideAnimation_; |
}; |
-- (id)initWithOwner:(BrowserWindowController*)owner browser:(Browser*)browser; |
+// Initializes a new InfoBarController. |
+- (id)initWithOwner:(BrowserWindowController*)owner browser:(Browser*)browser forURL:(const GURL&)url showButtons:(BOOL)show_buttons; |
+ |
+// Called when someone clicks on the OK or Cancel buttons. Subclasses |
+// must override if they do not hide the buttons. |
+- (void)allow:(id)sender; |
+- (void)deny:(id)sender; |
+ |
+- (void)showWindow; |
// Positions the fullscreen exit bubble in the top-center of the window. |
- (void)positionInWindowAtTop:(CGFloat)maxY width:(CGFloat)maxWidth; |