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

Side by Side Diff: chrome/browser/profiles/profiles_state.cc

Issue 117533002: [Mac] Redesign of the avatar menu button (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 11 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/profiles/profiles_state.h" 5 #include "chrome/browser/profiles/profiles_state.h"
6 6
7 #include "base/files/file_path.h" 7 #include "base/files/file_path.h"
8 #include "base/prefs/pref_registry_simple.h" 8 #include "base/prefs/pref_registry_simple.h"
9 #include "base/prefs/pref_service.h" 9 #include "base/prefs/pref_service.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 94
95 // Changing the profile name can invalidate the profile index. 95 // Changing the profile name can invalidate the profile index.
96 profile_index = cache.GetIndexOfProfileWithPath(profile_file_path); 96 profile_index = cache.GetIndexOfProfileWithPath(profile_file_path);
97 if (profile_index == std::string::npos) 97 if (profile_index == std::string::npos)
98 return; 98 return;
99 99
100 cache.SetIsUsingGAIANameOfProfileAtIndex(profile_index, false); 100 cache.SetIsUsingGAIANameOfProfileAtIndex(profile_index, false);
101 } 101 }
102 } 102 }
103 103
104 bool IsRegularOrGuestSession(Browser* browser) {
105 Profile* profile = browser->profile();
106 return (profile->IsGuestSession() || !profile->IsOffTheRecord());
Nico 2014/01/14 03:56:02 nit: no parens
noms (inactive) 2014/01/15 22:07:47 Done.
107 }
108
104 } // namespace profiles 109 } // namespace profiles
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698