OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/profiles/avatar_menu_model.h" | 5 #include "chrome/browser/profiles/avatar_menu_model.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/metrics/field_trial.h" | 9 #include "base/metrics/field_trial.h" |
10 #include "base/stl_util.h" | 10 #include "base/stl_util.h" |
11 #include "base/strings/string_number_conversions.h" | 11 #include "base/strings/string_number_conversions.h" |
12 #include "base/strings/utf_string_conversions.h" | 12 #include "base/strings/utf_string_conversions.h" |
13 #include "chrome/browser/browser_process.h" | 13 #include "chrome/browser/browser_process.h" |
| 14 #include "chrome/browser/chrome_notification_types.h" |
14 #include "chrome/browser/profiles/avatar_menu_model_observer.h" | 15 #include "chrome/browser/profiles/avatar_menu_model_observer.h" |
15 #include "chrome/browser/profiles/profile.h" | 16 #include "chrome/browser/profiles/profile.h" |
16 #include "chrome/browser/profiles/profile_info_cache.h" | 17 #include "chrome/browser/profiles/profile_info_cache.h" |
17 #include "chrome/browser/profiles/profile_info_util.h" | 18 #include "chrome/browser/profiles/profile_info_util.h" |
18 #include "chrome/browser/profiles/profile_manager.h" | 19 #include "chrome/browser/profiles/profile_manager.h" |
19 #include "chrome/browser/profiles/profile_metrics.h" | 20 #include "chrome/browser/profiles/profile_metrics.h" |
20 #include "chrome/browser/ui/browser.h" | 21 #include "chrome/browser/ui/browser.h" |
21 #include "chrome/browser/ui/browser_list.h" | 22 #include "chrome/browser/ui/browser_list.h" |
22 #include "chrome/browser/ui/browser_window.h" | 23 #include "chrome/browser/ui/browser_window.h" |
23 #include "chrome/browser/ui/chrome_pages.h" | 24 #include "chrome/browser/ui/chrome_pages.h" |
24 #include "chrome/browser/ui/host_desktop.h" | 25 #include "chrome/browser/ui/host_desktop.h" |
25 #include "chrome/browser/ui/startup/startup_browser_creator.h" | 26 #include "chrome/browser/ui/startup/startup_browser_creator.h" |
26 #include "chrome/common/chrome_notification_types.h" | |
27 #include "chrome/common/chrome_switches.h" | 27 #include "chrome/common/chrome_switches.h" |
28 #include "chrome/common/url_constants.h" | 28 #include "chrome/common/url_constants.h" |
29 #include "content/public/browser/browser_thread.h" | 29 #include "content/public/browser/browser_thread.h" |
30 #include "content/public/browser/notification_service.h" | 30 #include "content/public/browser/notification_service.h" |
31 #include "content/public/browser/site_instance.h" | 31 #include "content/public/browser/site_instance.h" |
32 #include "google_apis/gaia/gaia_urls.h" | 32 #include "google_apis/gaia/gaia_urls.h" |
33 #include "grit/generated_resources.h" | 33 #include "grit/generated_resources.h" |
34 #include "grit/theme_resources.h" | 34 #include "grit/theme_resources.h" |
35 #include "ui/base/l10n/l10n_util.h" | 35 #include "ui/base/l10n/l10n_util.h" |
36 #include "ui/base/resource/resource_bundle.h" | 36 #include "ui/base/resource/resource_bundle.h" |
(...skipping 303 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
340 contents->GetController().LoadURL( | 340 contents->GetController().LoadURL( |
341 logout_url, content::Referrer(), | 341 logout_url, content::Referrer(), |
342 content::PAGE_TRANSITION_GENERATED, std::string()); | 342 content::PAGE_TRANSITION_GENERATED, std::string()); |
343 | 343 |
344 // This object may be destructed when the menu closes but we need something | 344 // This object may be destructed when the menu closes but we need something |
345 // around to finish the sign-out process and close the profile windows. | 345 // around to finish the sign-out process and close the profile windows. |
346 new SignoutTracker(current_profile, GURL(landing_url), contents); | 346 new SignoutTracker(current_profile, GURL(landing_url), contents); |
347 | 347 |
348 return contents; // returned for testing purposes | 348 return contents; // returned for testing purposes |
349 } | 349 } |
OLD | NEW |