| Index: chrome/browser/chromeos/profiles/profile_helper.h
|
| diff --git a/chrome/browser/chromeos/profiles/profile_helper.h b/chrome/browser/chromeos/profiles/profile_helper.h
|
| index c0f8d349c3103d304804cae47fee7d16c4c49586..20fecf9f5dc59c45ef2781b44a4e6ddd396f0541 100644
|
| --- a/chrome/browser/chromeos/profiles/profile_helper.h
|
| +++ b/chrome/browser/chromeos/profiles/profile_helper.h
|
| @@ -11,6 +11,7 @@
|
| #include "base/callback_forward.h"
|
| #include "base/files/file_path.h"
|
| #include "base/macros.h"
|
| +#include "base/memory/scoped_ptr.h"
|
| #include "base/memory/weak_ptr.h"
|
| #include "chrome/browser/browsing_data/browsing_data_remover.h"
|
| #include "chrome/browser/chromeos/login/signin/oauth2_login_manager.h"
|
| @@ -34,6 +35,8 @@ class MultiUserWindowManagerChromeOSTest;
|
|
|
| namespace chromeos {
|
|
|
| +class FileFlusher;
|
| +
|
| // This helper class is used on Chrome OS to keep track of currently
|
| // active user profile.
|
| // Whenever active user is changed (either add another user into session or
|
| @@ -84,12 +87,15 @@ class ProfileHelper
|
| static bool IsSigninProfile(const Profile* profile);
|
|
|
| // Returns true when |profile| corresponds to owner's profile.
|
| - static bool IsOwnerProfile(Profile* profile);
|
| + static bool IsOwnerProfile(const Profile* profile);
|
|
|
| // Returns true when |profile| corresponds to the primary user profile
|
| // of the current session.
|
| static bool IsPrimaryProfile(const Profile* profile);
|
|
|
| + // Returns true when |profile| is for an ephemeral user.
|
| + static bool IsEphemeralUserProfile(const Profile* profile);
|
| +
|
| // Initialize a bunch of services that are tied to a browser profile.
|
| // TODO(dzhioev): Investigate whether or not this method is needed.
|
| void ProfileStartup(Profile* profile, bool process_startup);
|
| @@ -129,6 +135,9 @@ class ProfileHelper
|
| static std::string GetUserIdHashByUserIdForTesting(
|
| const std::string& user_id);
|
|
|
| + // Flushes all files of |profile|.
|
| + void FlushProfile(Profile* profile);
|
| +
|
| private:
|
| // TODO(nkostylev): Create a test API class that will be the only one allowed
|
| // to access private test methods.
|
| @@ -206,6 +215,8 @@ class ProfileHelper
|
| // always be returned by GetUserByProfile().
|
| static bool always_return_primary_user_for_testing;
|
|
|
| + scoped_ptr<FileFlusher> profile_flusher_;
|
| +
|
| base::WeakPtrFactory<ProfileHelper> weak_factory_;
|
|
|
| DISALLOW_COPY_AND_ASSIGN(ProfileHelper);
|
|
|