Index: chrome/browser/ui/cocoa/constrained_window/constrained_window_sheet_info.h |
diff --git a/chrome/browser/ui/cocoa/constrained_window/constrained_window_sheet_info.h b/chrome/browser/ui/cocoa/constrained_window/constrained_window_sheet_info.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..c9d1ffa1f8ce9fae06c9d1a78961d58f421daab3 |
--- /dev/null |
+++ b/chrome/browser/ui/cocoa/constrained_window/constrained_window_sheet_info.h |
@@ -0,0 +1,44 @@ |
+// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef CHROME_BROWSER_UI_COCOA_CONSTRAINED_WINDOW_CONSTRAINED_WINDOW_SHEET_INFO_H_ |
+#define CHROME_BROWSER_UI_COCOA_CONSTRAINED_WINDOW_CONSTRAINED_WINDOW_SHEET_INFO_H_ |
+ |
+#import <Cocoa/Cocoa.h> |
+ |
+#include "base/memory/scoped_nsobject.h" |
+ |
+// Information about a single sheet managed by CWSheetController. |
+@interface ConstrainedWindowSheetInfo : NSObject { |
+ scoped_nsobject<NSWindow> sheet_; |
+ scoped_nsobject<NSView> parentView_; |
+ scoped_nsobject<NSWindow> overlayWindow_; |
+ scoped_nsobject<NSAnimation> animation_; |
+ NSRect oldSheetFrame_; |
+ BOOL oldSheetAutoresizesSubviews_; |
+} |
+ |
+// Initializes a info object with for the given |sheet| and associated |
+// |parentView| and |overlayWindow|. |
+- (id)initWithSheet:(NSWindow*)sheet |
+ parentView:(NSView*)parentView |
+ overlayWindow:(NSWindow*)overlayWindow; |
+ |
+- (NSWindow*)sheet; |
+- (NSView*)parentView; |
+- (NSWindow*)overlayWindow; |
+ |
+- (void)setAnimation:(NSAnimation*)animation; |
+- (NSAnimation*)animation; |
+ |
+// Hides the sheet and the associated overlay window. Hiding is done in such |
+// a way as to not disturb the window cycle order. |
+- (void)hideSheet; |
+ |
+// Shows the sheet and the associated overlay window. |
+- (void)showSheet; |
+ |
+@end |
+ |
+#endif // CHROME_BROWSER_UI_COCOA_CONSTRAINED_WINDOW_CONSTRAINED_WINDOW_SHEET_INFO_H_ |