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

Unified Diff: chrome/browser/signin/signin_manager_factory.cc

Issue 898003002: [Cleanup] Const-correct the profile() method for the EasyUnlockService (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/signin/signin_manager_factory.cc
diff --git a/chrome/browser/signin/signin_manager_factory.cc b/chrome/browser/signin/signin_manager_factory.cc
index 7867c6941193e11137eeb81e55fcd658d74fae44..9e6ab705d2978452b4cb1aa90378c743c35d03ac 100644
--- a/chrome/browser/signin/signin_manager_factory.cc
+++ b/chrome/browser/signin/signin_manager_factory.cc
@@ -36,6 +36,13 @@ SigninManagerBase* SigninManagerFactory::GetForProfileIfExists(
GetInstance()->GetServiceForBrowserContext(profile, false));
}
+const SigninManagerBase* SigninManagerFactory::GetForProfileIfExists(
+ const Profile* profile) {
+ return static_cast<const SigninManagerBase*>(
+ GetInstance()->GetServiceForBrowserContext(
+ const_cast<Profile*>(profile), false));
+}
+
// static
SigninManagerBase* SigninManagerFactory::GetForProfile(
Profile* profile) {
@@ -55,6 +62,14 @@ SigninManager* SigninManagerFactory::GetForProfileIfExists(Profile* profile) {
return static_cast<SigninManager*>(
GetInstance()->GetServiceForBrowserContext(profile, false));
}
+
+// static
+const SigninManager* SigninManagerFactory::GetForProfileIfExists(
+ const Profile* profile) {
+ return static_cast<const SigninManager*>(
+ GetInstance()->GetServiceForBrowserContext(
+ const_cast<Profile*>(profile), false));
+}
#endif
// static

Powered by Google App Engine
This is Rietveld 408576698