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 #ifndef CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ | 5 #ifndef CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ |
6 #define CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ | 6 #define CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
100 } | 100 } |
101 | 101 |
102 ChromeURLRequestContext* extensions_request_context() const { | 102 ChromeURLRequestContext* extensions_request_context() const { |
103 return extensions_request_context_.get(); | 103 return extensions_request_context_.get(); |
104 } | 104 } |
105 | 105 |
106 BooleanPrefMember* safe_browsing_enabled() const { | 106 BooleanPrefMember* safe_browsing_enabled() const { |
107 return &safe_browsing_enabled_; | 107 return &safe_browsing_enabled_; |
108 } | 108 } |
109 | 109 |
110 BooleanPrefMember* enable_metrics() const { | |
111 return &enable_metrics_; | |
112 } | |
113 | |
110 net::TransportSecurityState* transport_security_state() const { | 114 net::TransportSecurityState* transport_security_state() const { |
111 return transport_security_state_.get(); | 115 return transport_security_state_.get(); |
112 } | 116 } |
113 | 117 |
114 chrome_browser_net::HttpServerPropertiesManager* | 118 chrome_browser_net::HttpServerPropertiesManager* |
115 http_server_properties_manager() const; | 119 http_server_properties_manager() const; |
116 | 120 |
121 bool is_incognito() const { | |
122 return is_incognito_; | |
123 } | |
124 | |
117 protected: | 125 protected: |
118 class AppRequestContext : public ChromeURLRequestContext { | 126 class AppRequestContext : public ChromeURLRequestContext { |
119 public: | 127 public: |
120 AppRequestContext(); | 128 AppRequestContext(); |
121 | 129 |
122 void SetCookieStore(net::CookieStore* cookie_store); | 130 void SetCookieStore(net::CookieStore* cookie_store); |
123 void SetHttpTransactionFactory(net::HttpTransactionFactory* http_factory); | 131 void SetHttpTransactionFactory(net::HttpTransactionFactory* http_factory); |
124 | 132 |
125 private: | 133 private: |
126 virtual ~AppRequestContext(); | 134 virtual ~AppRequestContext(); |
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
283 | 291 |
284 // Tracks whether or not we've been lazily initialized. | 292 // Tracks whether or not we've been lazily initialized. |
285 mutable bool initialized_; | 293 mutable bool initialized_; |
286 | 294 |
287 // Data from the UI thread from the Profile, used to initialize ProfileIOData. | 295 // Data from the UI thread from the Profile, used to initialize ProfileIOData. |
288 // Deleted after lazy initialization. | 296 // Deleted after lazy initialization. |
289 mutable scoped_ptr<ProfileParams> profile_params_; | 297 mutable scoped_ptr<ProfileParams> profile_params_; |
290 | 298 |
291 // Member variables which are pointed to by the various context objects. | 299 // Member variables which are pointed to by the various context objects. |
292 mutable BooleanPrefMember enable_referrers_; | 300 mutable BooleanPrefMember enable_referrers_; |
301 mutable BooleanPrefMember enable_metrics_; | |
293 mutable BooleanPrefMember clear_local_state_on_exit_; | 302 mutable BooleanPrefMember clear_local_state_on_exit_; |
294 mutable BooleanPrefMember safe_browsing_enabled_; | 303 mutable BooleanPrefMember safe_browsing_enabled_; |
295 // TODO(marja): Remove session_startup_pref_ if no longer needed. | 304 // TODO(marja): Remove session_startup_pref_ if no longer needed. |
296 mutable IntegerPrefMember session_startup_pref_; | 305 mutable IntegerPrefMember session_startup_pref_; |
297 | 306 |
298 // Pointed to by NetworkDelegate. | 307 // Pointed to by NetworkDelegate. |
299 mutable scoped_ptr<policy::URLBlacklistManager> url_blacklist_manager_; | 308 mutable scoped_ptr<policy::URLBlacklistManager> url_blacklist_manager_; |
300 | 309 |
301 // Pointed to by URLRequestContext. | 310 // Pointed to by URLRequestContext. |
302 mutable scoped_ptr<ChromeURLDataManagerBackend> | 311 mutable scoped_ptr<ChromeURLDataManagerBackend> |
(...skipping 23 matching lines...) Expand all Loading... | |
326 mutable AppRequestContextMap app_request_context_map_; | 335 mutable AppRequestContextMap app_request_context_map_; |
327 | 336 |
328 mutable scoped_ptr<ResourceContext> resource_context_; | 337 mutable scoped_ptr<ResourceContext> resource_context_; |
329 | 338 |
330 mutable scoped_refptr<ExtensionInfoMap> extension_info_map_; | 339 mutable scoped_refptr<ExtensionInfoMap> extension_info_map_; |
331 mutable scoped_refptr<CookieSettings> cookie_settings_; | 340 mutable scoped_refptr<CookieSettings> cookie_settings_; |
332 | 341 |
333 // TODO(jhawkins): Remove once crbug.com/102004 is fixed. | 342 // TODO(jhawkins): Remove once crbug.com/102004 is fixed. |
334 bool initialized_on_UI_thread_; | 343 bool initialized_on_UI_thread_; |
335 | 344 |
345 mutable bool is_incognito_; | |
battre
2012/04/27 09:44:35
why mutable?
SteveT
2012/04/27 14:17:47
Oops - that shouldn't be mutable anymore. Original
| |
346 | |
336 DISALLOW_COPY_AND_ASSIGN(ProfileIOData); | 347 DISALLOW_COPY_AND_ASSIGN(ProfileIOData); |
337 }; | 348 }; |
338 | 349 |
339 #endif // CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ | 350 #endif // CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ |
OLD | NEW |