Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(403)

Side by Side Diff: chrome/browser/chromeos/login/existing_user_controller.cc

Issue 15074010: suppress default chorme window on first login (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/ui/startup/startup_browser_creator.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/chromeos/login/existing_user_controller.h" 5 #include "chrome/browser/chromeos/login/existing_user_controller.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 23 matching lines...) Expand all
34 #include "chrome/browser/chromeos/login/wizard_controller.h" 34 #include "chrome/browser/chromeos/login/wizard_controller.h"
35 #include "chrome/browser/chromeos/net/connectivity_state_helper.h" 35 #include "chrome/browser/chromeos/net/connectivity_state_helper.h"
36 #include "chrome/browser/chromeos/profiles/profile_helper.h" 36 #include "chrome/browser/chromeos/profiles/profile_helper.h"
37 #include "chrome/browser/chromeos/settings/cros_settings.h" 37 #include "chrome/browser/chromeos/settings/cros_settings.h"
38 #include "chrome/browser/chromeos/settings/cros_settings_names.h" 38 #include "chrome/browser/chromeos/settings/cros_settings_names.h"
39 #include "chrome/browser/chromeos/system/statistics_provider.h" 39 #include "chrome/browser/chromeos/system/statistics_provider.h"
40 #include "chrome/browser/google/google_util.h" 40 #include "chrome/browser/google/google_util.h"
41 #include "chrome/browser/policy/policy_service.h" 41 #include "chrome/browser/policy/policy_service.h"
42 #include "chrome/browser/prefs/session_startup_pref.h" 42 #include "chrome/browser/prefs/session_startup_pref.h"
43 #include "chrome/common/chrome_notification_types.h" 43 #include "chrome/common/chrome_notification_types.h"
44 #include "chrome/common/chrome_switches.h"
44 #include "chrome/common/chrome_version_info.h" 45 #include "chrome/common/chrome_version_info.h"
45 #include "chrome/common/pref_names.h" 46 #include "chrome/common/pref_names.h"
46 #include "chrome/common/url_constants.h" 47 #include "chrome/common/url_constants.h"
47 #include "chromeos/chromeos_switches.h" 48 #include "chromeos/chromeos_switches.h"
48 #include "chromeos/dbus/dbus_thread_manager.h" 49 #include "chromeos/dbus/dbus_thread_manager.h"
49 #include "chromeos/dbus/power_manager_client.h" 50 #include "chromeos/dbus/power_manager_client.h"
50 #include "chromeos/dbus/session_manager_client.h" 51 #include "chromeos/dbus/session_manager_client.h"
51 #include "content/public/browser/browser_thread.h" 52 #include "content/public/browser/browser_thread.h"
52 #include "content/public/browser/notification_service.h" 53 #include "content/public/browser/notification_service.h"
53 #include "content/public/browser/notification_types.h" 54 #include "content/public/browser/notification_types.h"
(...skipping 954 matching lines...) Expand 10 before | Expand all | Expand 10 after
1008 } 1009 }
1009 1010
1010 ServicesCustomizationDocument* customization = 1011 ServicesCustomizationDocument* customization =
1011 ServicesCustomizationDocument::GetInstance(); 1012 ServicesCustomizationDocument::GetInstance();
1012 if (!ServicesCustomizationDocument::WasApplied() && 1013 if (!ServicesCustomizationDocument::WasApplied() &&
1013 customization->IsReady()) { 1014 customization->IsReady()) {
1014 // Since we don't use OEM start URL anymore, just mark as applied. 1015 // Since we don't use OEM start URL anymore, just mark as applied.
1015 customization->ApplyCustomization(); 1016 customization->ApplyCustomization();
1016 } 1017 }
1017 1018
1018 for (size_t i = 0; i < start_urls.size(); ++i) { 1019 if (UserManager::Get()->IsCurrentUserNew()) {
1019 CommandLine::ForCurrentProcess()->AppendArg(start_urls[i]); 1020 CommandLine::ForCurrentProcess()->AppendSwitchASCII(
1021 ::switches::kSilentLaunch, "");
1022 } else {
1023 for (size_t i = 0; i < start_urls.size(); ++i) {
1024 CommandLine::ForCurrentProcess()->AppendArg(start_urls[i]);
1025 }
1020 } 1026 }
1021 } 1027 }
1022 1028
1023 void ExistingUserController::OptionallyShowReleaseNotes( 1029 void ExistingUserController::OptionallyShowReleaseNotes(
1024 Profile* profile) const { 1030 Profile* profile) const {
1025 // TODO(nkostylev): Fix WizardControllerFlowTest case. 1031 // TODO(nkostylev): Fix WizardControllerFlowTest case.
1026 if (!profile || KioskModeSettings::Get()->IsKioskModeEnabled()) 1032 if (!profile || KioskModeSettings::Get()->IsKioskModeEnabled())
1027 return; 1033 return;
1028 if (UserManager::Get()->GetCurrentUserFlow()->ShouldSkipPostLoginScreens()) 1034 if (UserManager::Get()->GetCurrentUserFlow()->ShouldSkipPostLoginScreens())
1029 return; 1035 return;
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
1100 // changed. 1106 // changed.
1101 UserManager::Get()->SaveUserOAuthStatus( 1107 UserManager::Get()->SaveUserOAuthStatus(
1102 username, 1108 username,
1103 User::OAUTH2_TOKEN_STATUS_INVALID); 1109 User::OAUTH2_TOKEN_STATUS_INVALID);
1104 1110
1105 login_display_->SetUIEnabled(true); 1111 login_display_->SetUIEnabled(true);
1106 login_display_->ShowGaiaPasswordChanged(username); 1112 login_display_->ShowGaiaPasswordChanged(username);
1107 } 1113 }
1108 1114
1109 } // namespace chromeos 1115 } // namespace chromeos
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/startup/startup_browser_creator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698