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

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

Issue 10693109: Use Drive v2 API: enable behind --enable-drive-api flag (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 5 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
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/login_utils.h" 5 #include "chrome/browser/chromeos/login/login_utils.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <vector> 8 #include <vector>
9 9
10 #include "ash/ash_switches.h" 10 #include "ash/ash_switches.h"
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 100
101 // Increase logging level for Guest mode to avoid LOG(INFO) messages in logs. 101 // Increase logging level for Guest mode to avoid LOG(INFO) messages in logs.
102 const char kGuestModeLoggingLevel[] = "1"; 102 const char kGuestModeLoggingLevel[] = "1";
103 103
104 // Format of command line switch. 104 // Format of command line switch.
105 const char kSwitchFormatString[] = " --%s=\"%s\""; 105 const char kSwitchFormatString[] = " --%s=\"%s\"";
106 106
107 // User name which is used in the Guest session. 107 // User name which is used in the Guest session.
108 const char kGuestUserName[] = ""; 108 const char kGuestUserName[] = "";
109 109
110 // TODO(zelidrag): Figure out if we need to add more services here.
111 const char kServiceScopeChromeOSDocuments[] =
112 "https://docs.google.com/feeds/ "
113 "https://spreadsheets.google.com/feeds/ "
114 "https://docs.googleusercontent.com/";
satorux1 2012/07/09 15:58:11 could you create a separate patch to remove this?
kochi 2012/07/10 09:01:14 https://chromiumcodereview.appspot.com/10752021/
115
116 class InitializeCookieMonsterHelper { 110 class InitializeCookieMonsterHelper {
117 public: 111 public:
118 explicit InitializeCookieMonsterHelper( 112 explicit InitializeCookieMonsterHelper(
119 net::URLRequestContextGetter* new_context) 113 net::URLRequestContextGetter* new_context)
120 : ALLOW_THIS_IN_INITIALIZER_LIST(callback_(base::Bind( 114 : ALLOW_THIS_IN_INITIALIZER_LIST(callback_(base::Bind(
121 &InitializeCookieMonsterHelper::InitializeCookieMonster, 115 &InitializeCookieMonsterHelper::InitializeCookieMonster,
122 base::Unretained(this)))), 116 base::Unretained(this)))),
123 new_context_(new_context) { 117 new_context_(new_context) {
124 } 118 }
125 119
(...skipping 995 matching lines...) Expand 10 before | Expand all | Expand 10 after
1121 bool LoginUtils::IsWhitelisted(const std::string& username) { 1115 bool LoginUtils::IsWhitelisted(const std::string& username) {
1122 CrosSettings* cros_settings = CrosSettings::Get(); 1116 CrosSettings* cros_settings = CrosSettings::Get();
1123 bool allow_new_user = false; 1117 bool allow_new_user = false;
1124 cros_settings->GetBoolean(kAccountsPrefAllowNewUser, &allow_new_user); 1118 cros_settings->GetBoolean(kAccountsPrefAllowNewUser, &allow_new_user);
1125 if (allow_new_user) 1119 if (allow_new_user)
1126 return true; 1120 return true;
1127 return cros_settings->FindEmailInList(kAccountsPrefUsers, username); 1121 return cros_settings->FindEmailInList(kAccountsPrefUsers, username);
1128 } 1122 }
1129 1123
1130 } // namespace chromeos 1124 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698