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 #include "chrome/browser/ui/views/profiles/user_manager_view.h" | 5 #include "chrome/browser/ui/views/profiles/user_manager_view.h" |
6 | 6 |
7 #include "chrome/browser/browser_process.h" | 7 #include "chrome/browser/browser_process.h" |
8 #include "chrome/browser/lifetime/application_lifetime.h" | 8 #include "chrome/browser/lifetime/application_lifetime.h" |
9 #include "chrome/browser/profiles/profile_manager.h" | 9 #include "chrome/browser/profiles/profile_manager.h" |
10 #include "chrome/browser/profiles/profile_metrics.h" | 10 #include "chrome/browser/profiles/profile_metrics.h" |
11 #include "chrome/browser/profiles/profile_window.h" | 11 #include "chrome/browser/profiles/profile_window.h" |
12 #include "chrome/browser/ui/browser.h" | 12 #include "chrome/browser/ui/browser.h" |
13 #include "chrome/browser/ui/browser_dialogs.h" | 13 #include "chrome/browser/ui/browser_dialogs.h" |
14 #include "chrome/browser/ui/browser_window.h" | 14 #include "chrome/browser/ui/browser_window.h" |
15 #include "chrome/browser/ui/views/auto_keep_alive.h" | 15 #include "chrome/browser/ui/views/auto_keep_alive.h" |
16 #include "content/public/browser/web_contents.h" | 16 #include "content/public/browser/web_contents.h" |
17 #include "grit/generated_resources.h" | 17 #include "grit/chromium_strings.h" |
18 #include "ui/base/l10n/l10n_util.h" | 18 #include "ui/base/l10n/l10n_util.h" |
19 #include "ui/views/controls/webview/webview.h" | 19 #include "ui/views/controls/webview/webview.h" |
20 #include "ui/views/layout/fill_layout.h" | 20 #include "ui/views/layout/fill_layout.h" |
21 #include "ui/views/view.h" | 21 #include "ui/views/view.h" |
22 #include "ui/views/widget/widget.h" | 22 #include "ui/views/widget/widget.h" |
23 #include "ui/views/window/dialog_client_view.h" | 23 #include "ui/views/window/dialog_client_view.h" |
24 | 24 |
25 #if defined(OS_WIN) | 25 #if defined(OS_WIN) |
26 #include "chrome/browser/shell_integration.h" | 26 #include "chrome/browser/shell_integration.h" |
27 #include "ui/base/win/shell.h" | 27 #include "ui/base/win/shell.h" |
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
144 | 144 |
145 bool UserManagerView::CanResize() const { | 145 bool UserManagerView::CanResize() const { |
146 return true; | 146 return true; |
147 } | 147 } |
148 | 148 |
149 bool UserManagerView::CanMaximize() const { | 149 bool UserManagerView::CanMaximize() const { |
150 return true; | 150 return true; |
151 } | 151 } |
152 | 152 |
153 base::string16 UserManagerView::GetWindowTitle() const { | 153 base::string16 UserManagerView::GetWindowTitle() const { |
154 return l10n_util::GetStringUTF16(IDS_USER_MANAGER_SCREEN_TITLE); | 154 return l10n_util::GetStringUTF16(IDS_PRODUCT_NAME); |
155 } | 155 } |
156 | 156 |
157 int UserManagerView::GetDialogButtons() const { | 157 int UserManagerView::GetDialogButtons() const { |
158 return ui::DIALOG_BUTTON_NONE; | 158 return ui::DIALOG_BUTTON_NONE; |
159 } | 159 } |
160 | 160 |
161 void UserManagerView::WindowClosing() { | 161 void UserManagerView::WindowClosing() { |
162 // Now that the window is closed, we can allow a new one to be opened. | 162 // Now that the window is closed, we can allow a new one to be opened. |
163 // (WindowClosing comes in asynchronously from the call to Close() and we | 163 // (WindowClosing comes in asynchronously from the call to Close() and we |
164 // may have already opened a new instance). | 164 // may have already opened a new instance). |
165 if (instance_ == this) | 165 if (instance_ == this) |
166 instance_ = NULL; | 166 instance_ = NULL; |
167 } | 167 } |
168 | 168 |
169 bool UserManagerView::UseNewStyleForThisDialog() const { | 169 bool UserManagerView::UseNewStyleForThisDialog() const { |
170 return false; | 170 return false; |
171 } | 171 } |
OLD | NEW |