OLD | NEW |
---|---|
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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_VIEWS_PROFILES_SIGNIN_VIEW_CONTROLLER_DELEGATE_VIEWS_H _ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_PROFILES_SIGNIN_VIEW_CONTROLLER_DELEGATE_VIEWS_H _ |
6 #define CHROME_BROWSER_UI_VIEWS_PROFILES_SIGNIN_VIEW_CONTROLLER_DELEGATE_VIEWS_H _ | 6 #define CHROME_BROWSER_UI_VIEWS_PROFILES_SIGNIN_VIEW_CONTROLLER_DELEGATE_VIEWS_H _ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "chrome/browser/ui/profile_chooser_constants.h" | 9 #include "chrome/browser/ui/profile_chooser_constants.h" |
10 #include "chrome/browser/ui/signin_view_controller_delegate.h" | 10 #include "chrome/browser/ui/signin_view_controller_delegate.h" |
(...skipping 20 matching lines...) Expand all Loading... | |
31 class SigninViewControllerDelegateViews : public views::DialogDelegateView, | 31 class SigninViewControllerDelegateViews : public views::DialogDelegateView, |
32 public SigninViewControllerDelegate { | 32 public SigninViewControllerDelegate { |
33 public: | 33 public: |
34 // Creates and displays a constrained window containing |web_contents|. If | 34 // Creates and displays a constrained window containing |web_contents|. If |
35 // |wait_for_size| is true, the delegate will wait for ResizeNativeView() to | 35 // |wait_for_size| is true, the delegate will wait for ResizeNativeView() to |
36 // be called by the base class before displaying the constrained window. | 36 // be called by the base class before displaying the constrained window. |
37 SigninViewControllerDelegateViews( | 37 SigninViewControllerDelegateViews( |
38 SigninViewController* signin_view_controller, | 38 SigninViewController* signin_view_controller, |
39 std::unique_ptr<views::WebView> content_view, | 39 std::unique_ptr<views::WebView> content_view, |
40 Browser* browser, | 40 Browser* browser, |
41 DialogModalType dialog_modal_type, | |
41 bool wait_for_size); | 42 bool wait_for_size); |
42 | 43 |
43 // Creates the web view that contains the signin flow in |mode| using | 44 // Creates the web view that contains the signin flow in |mode| using |
44 // |profile| as the web content's profile, then sets |delegate| as the created | 45 // |profile| as the web content's profile, then sets |delegate| as the created |
45 // web content's delegate. | 46 // web content's delegate. |
46 static std::unique_ptr<views::WebView> CreateGaiaWebView( | 47 static std::unique_ptr<views::WebView> CreateGaiaWebView( |
47 content::WebContentsDelegate* delegate, | 48 content::WebContentsDelegate* delegate, |
48 profiles::BubbleViewMode mode, | 49 profiles::BubbleViewMode mode, |
49 Browser* browser, | 50 Browser* browser, |
50 signin_metrics::AccessPoint access_point); | 51 signin_metrics::AccessPoint access_point); |
(...skipping 21 matching lines...) Expand all Loading... | |
72 | 73 |
73 ~SigninViewControllerDelegateViews() override; | 74 ~SigninViewControllerDelegateViews() override; |
74 | 75 |
75 views::WebView* content_view_; | 76 views::WebView* content_view_; |
76 views::Widget* modal_signin_widget_; // Not owned. | 77 views::Widget* modal_signin_widget_; // Not owned. |
77 | 78 |
78 // wait_for_size_ stores whether the dialog should only be shown after its | 79 // wait_for_size_ stores whether the dialog should only be shown after its |
79 // content's size has been laid out and measured so that the constrained | 80 // content's size has been laid out and measured so that the constrained |
80 // window is sized to the content. | 81 // window is sized to the content. |
81 bool wait_for_size_; | 82 bool wait_for_size_; |
83 | |
jlebel
2017/01/10 13:20:18
I would remove the empty line.
msarda
2017/01/10 17:32:27
We prefer having a blank line if the comment start
| |
84 // The dialog modal presentation type. | |
Peter Kasting
2017/01/11 01:24:45
Nit: I agree with your rationale on adding blank l
msarda
2017/01/11 09:54:25
Done.
| |
85 DialogModalType dialog_modal_type_; | |
86 | |
jlebel
2017/01/10 13:20:18
Same here.
msarda
2017/01/10 17:32:27
Ditto.
| |
82 Browser* browser_; | 87 Browser* browser_; |
83 | 88 |
84 DISALLOW_COPY_AND_ASSIGN(SigninViewControllerDelegateViews); | 89 DISALLOW_COPY_AND_ASSIGN(SigninViewControllerDelegateViews); |
85 }; | 90 }; |
86 | 91 |
87 #endif // CHROME_BROWSER_UI_VIEWS_PROFILES_SIGNIN_VIEW_CONTROLLER_DELEGATE_VIEW S_H_ | 92 #endif // CHROME_BROWSER_UI_VIEWS_PROFILES_SIGNIN_VIEW_CONTROLLER_DELEGATE_VIEW S_H_ |
OLD | NEW |