| 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 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 201 | 201 |
| 202 // Initialize the member needed to track the metrics enabled state. This is | 202 // Initialize the member needed to track the metrics enabled state. This is |
| 203 // only to be called on the UI thread. | 203 // only to be called on the UI thread. |
| 204 void InitializeMetricsEnabledStateOnUIThread(); | 204 void InitializeMetricsEnabledStateOnUIThread(); |
| 205 | 205 |
| 206 // Returns whether or not metrics reporting is enabled in the browser instance | 206 // Returns whether or not metrics reporting is enabled in the browser instance |
| 207 // on which this profile resides. This is safe for use from the IO thread, and | 207 // on which this profile resides. This is safe for use from the IO thread, and |
| 208 // should only be called from there. | 208 // should only be called from there. |
| 209 bool GetMetricsEnabledStateOnIOThread() const; | 209 bool GetMetricsEnabledStateOnIOThread() const; |
| 210 | 210 |
| 211 void set_client_cert_store_factory_for_testing( |
| 212 const base::Callback<scoped_ptr<net::ClientCertStore>()>& factory) { |
| 213 client_cert_store_factory_ = factory; |
| 214 } |
| 215 |
| 211 protected: | 216 protected: |
| 212 // A URLRequestContext for media that owns its HTTP factory, to ensure | 217 // A URLRequestContext for media that owns its HTTP factory, to ensure |
| 213 // it is deleted. | 218 // it is deleted. |
| 214 class MediaRequestContext : public ChromeURLRequestContext { | 219 class MediaRequestContext : public ChromeURLRequestContext { |
| 215 public: | 220 public: |
| 216 MediaRequestContext(); | 221 MediaRequestContext(); |
| 217 | 222 |
| 218 void SetHttpTransactionFactory( | 223 void SetHttpTransactionFactory( |
| 219 scoped_ptr<net::HttpTransactionFactory> http_factory); | 224 scoped_ptr<net::HttpTransactionFactory> http_factory); |
| 220 | 225 |
| (...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 445 // Tracks whether or not we've been lazily initialized. | 450 // Tracks whether or not we've been lazily initialized. |
| 446 mutable bool initialized_; | 451 mutable bool initialized_; |
| 447 | 452 |
| 448 // Data from the UI thread from the Profile, used to initialize ProfileIOData. | 453 // Data from the UI thread from the Profile, used to initialize ProfileIOData. |
| 449 // Deleted after lazy initialization. | 454 // Deleted after lazy initialization. |
| 450 mutable scoped_ptr<ProfileParams> profile_params_; | 455 mutable scoped_ptr<ProfileParams> profile_params_; |
| 451 | 456 |
| 452 // Provides access to the email addresses of all signed in profiles. | 457 // Provides access to the email addresses of all signed in profiles. |
| 453 mutable scoped_ptr<SigninNamesOnIOThread> signin_names_; | 458 mutable scoped_ptr<SigninNamesOnIOThread> signin_names_; |
| 454 | 459 |
| 460 // Used for testing. |
| 461 mutable base::Callback<scoped_ptr<net::ClientCertStore>()> |
| 462 client_cert_store_factory_; |
| 463 |
| 455 mutable StringPrefMember google_services_user_account_id_; | 464 mutable StringPrefMember google_services_user_account_id_; |
| 456 mutable StringPrefMember google_services_username_; | 465 mutable StringPrefMember google_services_username_; |
| 457 mutable StringPrefMember google_services_username_pattern_; | 466 mutable StringPrefMember google_services_username_pattern_; |
| 458 mutable BooleanPrefMember reverse_autologin_enabled_; | 467 mutable BooleanPrefMember reverse_autologin_enabled_; |
| 459 | 468 |
| 460 // During the reverse autologin request chain processing, this member saves | 469 // During the reverse autologin request chain processing, this member saves |
| 461 // the email of the google account that is being signed into. | 470 // the email of the google account that is being signed into. |
| 462 std::string reverse_autologin_pending_email_; | 471 std::string reverse_autologin_pending_email_; |
| 463 | 472 |
| 464 mutable StringListPrefMember one_click_signin_rejected_email_list_; | 473 mutable StringListPrefMember one_click_signin_rejected_email_list_; |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 534 | 543 |
| 535 // TODO(jhawkins): Remove once crbug.com/102004 is fixed. | 544 // TODO(jhawkins): Remove once crbug.com/102004 is fixed. |
| 536 bool initialized_on_UI_thread_; | 545 bool initialized_on_UI_thread_; |
| 537 | 546 |
| 538 bool is_incognito_; | 547 bool is_incognito_; |
| 539 | 548 |
| 540 DISALLOW_COPY_AND_ASSIGN(ProfileIOData); | 549 DISALLOW_COPY_AND_ASSIGN(ProfileIOData); |
| 541 }; | 550 }; |
| 542 | 551 |
| 543 #endif // CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ | 552 #endif // CHROME_BROWSER_PROFILES_PROFILE_IO_DATA_H_ |
| OLD | NEW |