Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 // This class gathers state related to a single user profile. | 5 // This class gathers state related to a single user profile. |
| 6 | 6 |
| 7 #ifndef CHROME_BROWSER_PROFILES_PROFILE_H_ | 7 #ifndef CHROME_BROWSER_PROFILES_PROFILE_H_ |
| 8 #define CHROME_BROWSER_PROFILES_PROFILE_H_ | 8 #define CHROME_BROWSER_PROFILES_PROFILE_H_ |
| 9 #pragma once | 9 #pragma once |
| 10 | 10 |
| (...skipping 362 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 373 virtual HostContentSettingsMap* GetHostContentSettingsMap() = 0; | 373 virtual HostContentSettingsMap* GetHostContentSettingsMap() = 0; |
| 374 | 374 |
| 375 // Returns the user style sheet watcher. | 375 // Returns the user style sheet watcher. |
| 376 virtual UserStyleSheetWatcher* GetUserStyleSheetWatcher() = 0; | 376 virtual UserStyleSheetWatcher* GetUserStyleSheetWatcher() = 0; |
| 377 | 377 |
| 378 // Returns the find bar state for this profile. The find bar state is lazily | 378 // Returns the find bar state for this profile. The find bar state is lazily |
| 379 // created the first time that this method is called. | 379 // created the first time that this method is called. |
| 380 virtual FindBarState* GetFindBarState() = 0; | 380 virtual FindBarState* GetFindBarState() = 0; |
| 381 | 381 |
| 382 // Returns true if this profile has a profile sync service. | 382 // Returns true if this profile has a profile sync service. |
| 383 virtual bool HasProfileSyncService() const = 0; | 383 // TODO(tim): Bug 93922 - remove this. |
| 384 virtual bool HasProfileSyncService() = 0; | |
|
Andrew T Wilson (Slow)
2012/01/17 20:25:41
Why is this no longer const? Not a huge deal since
tim (not reviewing)
2012/01/17 23:44:17
Because it now uses GetServiceForProfile, which ta
| |
| 384 | 385 |
| 385 // Returns true if the last time this profile was open it was exited cleanly. | 386 // Returns true if the last time this profile was open it was exited cleanly. |
| 386 virtual bool DidLastSessionExitCleanly() = 0; | 387 virtual bool DidLastSessionExitCleanly() = 0; |
| 387 | 388 |
| 388 // Returns the BookmarkModel, creating if not yet created. | 389 // Returns the BookmarkModel, creating if not yet created. |
| 389 virtual BookmarkModel* GetBookmarkModel() = 0; | 390 virtual BookmarkModel* GetBookmarkModel() = 0; |
| 390 | 391 |
| 391 // Returns the ProtocolHandlerRegistry, creating if not yet created. | 392 // Returns the ProtocolHandlerRegistry, creating if not yet created. |
| 392 virtual ProtocolHandlerRegistry* GetProtocolHandlerRegistry() = 0; | 393 virtual ProtocolHandlerRegistry* GetProtocolHandlerRegistry() = 0; |
| 393 | 394 |
| 394 // Returns the SigninManager, creating if not yet created. | 395 // Returns the SigninManager, creating if not yet created. |
| 395 virtual SigninManager* GetSigninManager() = 0; | 396 virtual SigninManager* GetSigninManager() = 0; |
| 396 | 397 |
| 397 // Returns the Gaia Token Service, creating if not yet created. | 398 // Returns the Gaia Token Service, creating if not yet created. |
| 398 virtual TokenService* GetTokenService() = 0; | 399 virtual TokenService* GetTokenService() = 0; |
| 399 | 400 |
| 400 // Returns the ProfileSyncService, creating if not yet created. | 401 // Returns the ProfileSyncService, creating if not yet created. |
| 402 // TODO(tim): Bug 93922 - remove this. | |
| 401 virtual ProfileSyncService* GetProfileSyncService() = 0; | 403 virtual ProfileSyncService* GetProfileSyncService() = 0; |
| 402 | 404 |
| 403 // Return whether 2 profiles are the same. 2 profiles are the same if they | 405 // Return whether 2 profiles are the same. 2 profiles are the same if they |
| 404 // represent the same profile. This can happen if there is pointer equality | 406 // represent the same profile. This can happen if there is pointer equality |
| 405 // or if one profile is the incognito version of another profile (or vice | 407 // or if one profile is the incognito version of another profile (or vice |
| 406 // versa). | 408 // versa). |
| 407 virtual bool IsSameProfile(Profile* profile) = 0; | 409 virtual bool IsSameProfile(Profile* profile) = 0; |
| 408 | 410 |
| 409 // Returns the time the profile was started. This is not the time the profile | 411 // Returns the time the profile was started. This is not the time the profile |
| 410 // was created, rather it is the time the user started chrome and logged into | 412 // was created, rather it is the time the user started chrome and logged into |
| (...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 570 struct hash<Profile*> { | 572 struct hash<Profile*> { |
| 571 std::size_t operator()(Profile* const& p) const { | 573 std::size_t operator()(Profile* const& p) const { |
| 572 return reinterpret_cast<std::size_t>(p); | 574 return reinterpret_cast<std::size_t>(p); |
| 573 } | 575 } |
| 574 }; | 576 }; |
| 575 | 577 |
| 576 } // namespace __gnu_cxx | 578 } // namespace __gnu_cxx |
| 577 #endif | 579 #endif |
| 578 | 580 |
| 579 #endif // CHROME_BROWSER_PROFILES_PROFILE_H_ | 581 #endif // CHROME_BROWSER_PROFILES_PROFILE_H_ |
| OLD | NEW |