Index: components/wifi_sync/wifi_credential_syncable_service_factory.h |
diff --git a/components/wifi_sync/wifi_credential_syncable_service_factory.h b/components/wifi_sync/wifi_credential_syncable_service_factory.h |
index be1dae524010da6fe08414e688fb662a6810c264..be5b6c506a21fe68cd47f44c6e88857e66f04d2e 100644 |
--- a/components/wifi_sync/wifi_credential_syncable_service_factory.h |
+++ b/components/wifi_sync/wifi_credential_syncable_service_factory.h |
@@ -6,6 +6,7 @@ |
#define COMPONENTS_WIFI_SYNC_WIFI_CREDENTIAL_SYNCABLE_SERVICE_FACTORY_H_ |
#include "base/macros.h" |
+#include "base/memory/scoped_ptr.h" |
#include "base/memory/singleton.h" |
#include "components/keyed_service/content/browser_context_keyed_service_factory.h" |
@@ -15,6 +16,7 @@ class BrowserContext; |
namespace wifi_sync { |
+class WifiConfigDelegate; |
class WifiCredentialSyncableService; |
// Singleton that owns all WifiCredentialSyncableServices and |
@@ -29,12 +31,15 @@ class WifiCredentialSyncableServiceFactory |
static WifiCredentialSyncableService* GetForBrowserContext( |
content::BrowserContext* browser_context); |
- // Returns the singleton instance. As this class has no public |
- // instance methods, this function is not generally useful for |
- // external callers. This function is public only so that the |
- // Singleton template can reference it. |
+ // Returns the singleton instance. |
static WifiCredentialSyncableServiceFactory* GetInstance(); |
+#if defined(OS_CHROMEOS) |
+ void set_ignore_login_state_for_test(bool new_value) { |
+ ignore_login_state_for_test_ = new_value; |
+ } |
+#endif |
+ |
private: |
friend struct DefaultSingletonTraits<WifiCredentialSyncableServiceFactory>; |
@@ -45,6 +50,22 @@ class WifiCredentialSyncableServiceFactory |
KeyedService* BuildServiceInstanceFor( |
content::BrowserContext* context) const override; |
+#if defined(OS_CHROMEOS) |
+ // Returns a scoped pointer to a WifiConfigDelegate, which can be |
+ // used to configure the ChromeOS Wi-Fi settings associated with |
+ // |context|. |
+ scoped_ptr<WifiConfigDelegate> BuildWifiConfigDelegateChromeOs( |
+ content::BrowserContext* context) const; |
+#endif |
+ |
+#if defined(OS_CHROMEOS) |
+ // Whether or not we should use LoginState to associate a new |
+ // SyncableService with a Shill profile. Should be set to true in |
+ // sync integration tests, where it is not possible to control |
+ // LoginState at the time SyncableServices are constructed. |
+ bool ignore_login_state_for_test_ = false; |
stevenjb
2015/01/28 22:47:24
nice.
|
+#endif |
+ |
DISALLOW_COPY_AND_ASSIGN(WifiCredentialSyncableServiceFactory); |
}; |