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

Side by Side Diff: chrome/browser/signin/chrome_signin_client.cc

Issue 192253002: Rename SigninManagerDelegate to SigninClient (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 9 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/signin/chrome_signin_manager_delegate.h" 5 #include "chrome/browser/signin/chrome_signin_client.h"
6 6
7 #include "chrome/browser/content_settings/cookie_settings.h" 7 #include "chrome/browser/content_settings/cookie_settings.h"
8 #include "url/gurl.h" 8 #include "url/gurl.h"
9 9
10 namespace { 10 namespace {
11 11
12 const char kGoogleAccountsUrl[] = "https://accounts.google.com"; 12 const char kGoogleAccountsUrl[] = "https://accounts.google.com";
13 13
14 } // namespace 14 } // namespace
15 15
16 ChromeSigninManagerDelegate::ChromeSigninManagerDelegate(Profile* profile) 16 ChromeSigninClient::ChromeSigninClient(Profile* profile) : profile_(profile) {}
17 : profile_(profile) {
18 }
19 17
20 ChromeSigninManagerDelegate::~ChromeSigninManagerDelegate() { 18 ChromeSigninClient::~ChromeSigninClient() {}
21 }
22 19
23 // static 20 // static
24 bool ChromeSigninManagerDelegate::ProfileAllowsSigninCookies(Profile* profile) { 21 bool ChromeSigninClient::ProfileAllowsSigninCookies(Profile* profile) {
25 CookieSettings* cookie_settings = 22 CookieSettings* cookie_settings =
26 CookieSettings::Factory::GetForProfile(profile).get(); 23 CookieSettings::Factory::GetForProfile(profile).get();
27 return SettingsAllowSigninCookies(cookie_settings); 24 return SettingsAllowSigninCookies(cookie_settings);
28 } 25 }
29 26
30 // static 27 // static
31 bool ChromeSigninManagerDelegate::SettingsAllowSigninCookies( 28 bool ChromeSigninClient::SettingsAllowSigninCookies(
32 CookieSettings* cookie_settings) { 29 CookieSettings* cookie_settings) {
33 return cookie_settings && 30 return cookie_settings &&
34 cookie_settings->IsSettingCookieAllowed(GURL(kGoogleAccountsUrl), 31 cookie_settings->IsSettingCookieAllowed(GURL(kGoogleAccountsUrl),
35 GURL(kGoogleAccountsUrl)); 32 GURL(kGoogleAccountsUrl));
36 } 33 }
37 34
38 35 bool ChromeSigninClient::AreSigninCookiesAllowed() {
39 bool ChromeSigninManagerDelegate::AreSigninCookiesAllowed() {
40 return ProfileAllowsSigninCookies(profile_); 36 return ProfileAllowsSigninCookies(profile_);
41 } 37 }
OLDNEW
« no previous file with comments | « chrome/browser/signin/chrome_signin_client.h ('k') | chrome/browser/signin/chrome_signin_manager_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698