Update To 11.40.268.0
[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 class GURL;
13
14 namespace autofill {
15 class AutofillDialogCocoa;
16 class AutofillDialogSignInDelegate;
17 }
18
19 namespace content {
20 class WebContents;
21 class NavigationController;
22 }
23
24 // Controls the sign-in dialog of the AutofillDialog.
25 @interface AutofillSignInContainer : NSViewController {
26  @private
27   autofill::AutofillDialogCocoa* dialog_;  // Not owned.
28   scoped_ptr<content::WebContents> webContents_;
29   scoped_ptr<autofill::AutofillDialogSignInDelegate> signInDelegate_;
30
31   // The minimum and maximum sizes for the web view.
32   NSSize maxSize_;
33   NSSize minSize_;
34
35   // The preferred size for this view, including both the web view and the
36   // bottom padding.
37   NSSize preferredSize_;
38 }
39
40 @property(assign, nonatomic) NSSize preferredSize;
41
42 - (id)initWithDialog:(autofill::AutofillDialogCocoa*)dialog;
43 - (void)loadSignInPage:(const GURL&)url;
44 - (content::NavigationController*)navigationController;
45 - (void)constrainSizeToMinimum:(NSSize)minSize maximum:(NSSize)maximum;
46 - (content::WebContents*)webContents;
47
48 @end
49
50 #endif  // CHROME_BROWSER_UI_COCOA_AUTOFILL_AUTOFILL_SIGN_IN_CONTAINER_H_