4805729f3ec4f09093b947546a52009122962e5e
[platform/framework/web/crosswalk.git] / src / chrome / browser / ui / cocoa / autofill / autofill_sign_in_container.h
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_UI_COCOA_AUTOFILL_AUTOFILL_SIGN_IN_CONTAINER_H_
6 #define CHROME_BROWSER_UI_COCOA_AUTOFILL_AUTOFILL_SIGN_IN_CONTAINER_H_
7
8 #import <Cocoa/Cocoa.h>
9
10 #include "base/memory/scoped_ptr.h"
11
12 namespace autofill {
13 class AutofillDialogCocoa;
14 class AutofillDialogSignInDelegate;
15 }
16
17 namespace content {
18 class WebContents;
19 class NavigationController;
20 }
21
22 // Controls the sign-in dialog of the AutofillDialog.
23 @interface AutofillSignInContainer : NSViewController {
24  @private
25   autofill::AutofillDialogCocoa* dialog_;  // Not owned.
26   scoped_ptr<content::WebContents> webContents_;
27   scoped_ptr<autofill::AutofillDialogSignInDelegate> signInDelegate_;
28
29   // The minimum and maximum sizes for the web view.
30   NSSize maxSize_;
31   NSSize minSize_;
32
33   // The preferred size for this view, including both the web view and the
34   // bottom padding.
35   NSSize preferredSize_;
36 }
37
38 @property(assign, nonatomic) NSSize preferredSize;
39
40 - (id)initWithDialog:(autofill::AutofillDialogCocoa*)dialog;
41 - (void)loadSignInPage;
42 - (content::NavigationController*)navigationController;
43 - (void)constrainSizeToMinimum:(NSSize)minSize maximum:(NSSize)maximum;
44 - (content::WebContents*)webContents;
45
46 @end
47
48 #endif  // CHROME_BROWSER_UI_COCOA_AUTOFILL_AUTOFILL_SIGN_IN_CONTAINER_H_