OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 class PrerenderManager; | 48 class PrerenderManager; |
49 } | 49 } |
50 | 50 |
51 namespace speech_input { | 51 namespace speech_input { |
52 class SpeechRecognizer; | 52 class SpeechRecognizer; |
53 } | 53 } |
54 | 54 |
55 class AutocompleteClassifier; | 55 class AutocompleteClassifier; |
56 class BookmarkModel; | 56 class BookmarkModel; |
57 class ChromeAppCacheService; | 57 class ChromeAppCacheService; |
| 58 class ChromeDownloadManagerDelegate; |
58 class ChromeURLDataManager; | 59 class ChromeURLDataManager; |
59 class Extension; | 60 class Extension; |
60 class ExtensionDevToolsManager; | 61 class ExtensionDevToolsManager; |
61 class ExtensionEventRouter; | 62 class ExtensionEventRouter; |
62 class ExtensionInfoMap; | 63 class ExtensionInfoMap; |
63 class ExtensionMessageService; | 64 class ExtensionMessageService; |
64 class ExtensionPrefValueMap; | 65 class ExtensionPrefValueMap; |
65 class ExtensionProcessManager; | 66 class ExtensionProcessManager; |
66 class ExtensionService; | 67 class ExtensionService; |
67 class ExtensionSpecialStoragePolicy; | 68 class ExtensionSpecialStoragePolicy; |
(...skipping 480 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
548 | 549 |
549 // Creates an OffTheRecordProfile which points to this Profile. | 550 // Creates an OffTheRecordProfile which points to this Profile. |
550 Profile* CreateOffTheRecordProfile(); | 551 Profile* CreateOffTheRecordProfile(); |
551 | 552 |
552 protected: | 553 protected: |
553 friend class OffTheRecordProfileImpl; | 554 friend class OffTheRecordProfileImpl; |
554 | 555 |
555 static net::URLRequestContextGetter* default_request_context_; | 556 static net::URLRequestContextGetter* default_request_context_; |
556 | 557 |
557 private: | 558 private: |
| 559 friend class DownloadTest; |
| 560 |
| 561 // Allow replacement of the download manager delegate, for interposition |
| 562 // on browser tests. Note that this takes ownership of |delegate|. |
| 563 virtual void SetDownloadManagerDelegate( |
| 564 ChromeDownloadManagerDelegate* delegate) = 0; |
| 565 |
558 // ***DEPRECATED**: You should be passing in the specific profile's | 566 // ***DEPRECATED**: You should be passing in the specific profile's |
559 // URLRequestContextGetter or using the system URLRequestContextGetter. | 567 // URLRequestContextGetter or using the system URLRequestContextGetter. |
560 // | 568 // |
561 // Returns the request context for the "default" profile. This may be called | 569 // Returns the request context for the "default" profile. This may be called |
562 // from any thread. This CAN return NULL if a first request context has not | 570 // from any thread. This CAN return NULL if a first request context has not |
563 // yet been created. If necessary, listen on the UI thread for | 571 // yet been created. If necessary, listen on the UI thread for |
564 // NOTIFY_DEFAULT_REQUEST_CONTEXT_AVAILABLE. | 572 // NOTIFY_DEFAULT_REQUEST_CONTEXT_AVAILABLE. |
565 static net::URLRequestContextGetter* GetDefaultRequestContext(); | 573 static net::URLRequestContextGetter* GetDefaultRequestContext(); |
566 | 574 |
567 bool restored_last_session_; | 575 bool restored_last_session_; |
(...skipping 15 matching lines...) Expand all Loading... |
583 struct hash<Profile*> { | 591 struct hash<Profile*> { |
584 std::size_t operator()(Profile* const& p) const { | 592 std::size_t operator()(Profile* const& p) const { |
585 return reinterpret_cast<std::size_t>(p); | 593 return reinterpret_cast<std::size_t>(p); |
586 } | 594 } |
587 }; | 595 }; |
588 | 596 |
589 } // namespace __gnu_cxx | 597 } // namespace __gnu_cxx |
590 #endif | 598 #endif |
591 | 599 |
592 #endif // CHROME_BROWSER_PROFILES_PROFILE_H_ | 600 #endif // CHROME_BROWSER_PROFILES_PROFILE_H_ |
OLD | NEW |