Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_USER_MANAGER_VIEW_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_PROFILES_USER_MANAGER_VIEW_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_PROFILES_USER_MANAGER_VIEW_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_PROFILES_USER_MANAGER_VIEW_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
| (...skipping 25 matching lines...) Expand all Loading... | |
| 36 void DisplayErrorMessage(); | 36 void DisplayErrorMessage(); |
| 37 | 37 |
| 38 private: | 38 private: |
| 39 UserManagerProfileDialogDelegate(); | 39 UserManagerProfileDialogDelegate(); |
| 40 | 40 |
| 41 // Before its destruction, tells its parent container to reset its reference | 41 // Before its destruction, tells its parent container to reset its reference |
| 42 // to the UserManagerProfileDialogDelegate. | 42 // to the UserManagerProfileDialogDelegate. |
| 43 void OnDialogDestroyed(); | 43 void OnDialogDestroyed(); |
| 44 | 44 |
| 45 // views::DialogDelegate: | 45 // views::DialogDelegate: |
| 46 gfx::Size GetPreferredSize() const override; | 46 gfx::Size GetUnsnappedPreferredSize() const override; |
| 47 bool CanResize() const override; | 47 bool CanResize() const override; |
| 48 bool CanMaximize() const override; | 48 bool CanMaximize() const override; |
| 49 bool CanMinimize() const override; | 49 bool CanMinimize() const override; |
| 50 bool ShouldUseCustomFrame() const override; | 50 bool ShouldUseCustomFrame() const override; |
| 51 ui::ModalType GetModalType() const override; | 51 ui::ModalType GetModalType() const override; |
| 52 void DeleteDelegate() override; | 52 void DeleteDelegate() override; |
| 53 base::string16 GetWindowTitle() const override; | 53 base::string16 GetWindowTitle() const override; |
| 54 int GetDialogButtons() const override; | 54 int GetDialogButtons() const override; |
| 55 views::View* GetInitiallyFocusedView() override; | 55 views::View* GetInitiallyFocusedView() override; |
| 56 | 56 |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 111 ~UserManagerView() override; | 111 ~UserManagerView() override; |
| 112 | 112 |
| 113 // Resets delegate_ to nullptr when delegate_ is no longer alive. | 113 // Resets delegate_ to nullptr when delegate_ is no longer alive. |
| 114 void OnDialogDestroyed(); | 114 void OnDialogDestroyed(); |
| 115 | 115 |
| 116 // Creates dialog and initializes UI. | 116 // Creates dialog and initializes UI. |
| 117 void Init(Profile* guest_profile, const GURL& url); | 117 void Init(Profile* guest_profile, const GURL& url); |
| 118 | 118 |
| 119 // views::View: | 119 // views::View: |
| 120 bool AcceleratorPressed(const ui::Accelerator& accelerator) override; | 120 bool AcceleratorPressed(const ui::Accelerator& accelerator) override; |
| 121 gfx::Size GetPreferredSize() const override; | |
| 122 | 121 |
| 123 // views::DialogDelegateView: | 122 // views::DialogDelegateView: |
|
Peter Kasting
2017/03/30 00:35:35
Nit: Combine with above section
| |
| 124 bool CanResize() const override; | 123 bool CanResize() const override; |
| 125 bool CanMaximize() const override; | 124 bool CanMaximize() const override; |
| 126 bool CanMinimize() const override; | 125 bool CanMinimize() const override; |
| 126 gfx::Size GetUnsnappedPreferredSize() const override; | |
| 127 base::string16 GetWindowTitle() const override; | 127 base::string16 GetWindowTitle() const override; |
| 128 int GetDialogButtons() const override; | 128 int GetDialogButtons() const override; |
| 129 void WindowClosing() override; | 129 void WindowClosing() override; |
| 130 bool ShouldUseCustomFrame() const override; | 130 bool ShouldUseCustomFrame() const override; |
| 131 | 131 |
| 132 views::WebView* web_view_; | 132 views::WebView* web_view_; |
| 133 | 133 |
| 134 UserManagerProfileDialogDelegate* delegate_; | 134 UserManagerProfileDialogDelegate* delegate_; |
| 135 | 135 |
| 136 std::unique_ptr<ScopedKeepAlive> keep_alive_; | 136 std::unique_ptr<ScopedKeepAlive> keep_alive_; |
| 137 base::Time user_manager_started_showing_; | 137 base::Time user_manager_started_showing_; |
| 138 | 138 |
| 139 base::FilePath signin_profile_path_; | 139 base::FilePath signin_profile_path_; |
| 140 | 140 |
| 141 DISALLOW_COPY_AND_ASSIGN(UserManagerView); | 141 DISALLOW_COPY_AND_ASSIGN(UserManagerView); |
| 142 }; | 142 }; |
| 143 | 143 |
| 144 #endif // CHROME_BROWSER_UI_VIEWS_PROFILES_USER_MANAGER_VIEW_H_ | 144 #endif // CHROME_BROWSER_UI_VIEWS_PROFILES_USER_MANAGER_VIEW_H_ |
| OLD | NEW |