Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(645)

Unified Diff: content/browser/geolocation/wifi_data_provider_manager.cc

Issue 486203004: Clean up WifiDataProvider(Manager) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/browser/geolocation/wifi_data_provider_manager.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/geolocation/wifi_data_provider_manager.cc
diff --git a/content/browser/geolocation/wifi_data_provider_manager.cc b/content/browser/geolocation/wifi_data_provider_manager.cc
index 1dc1770a1911222d7dbae080d18c15e6ac2fd3f5..84e3ef8ab093b1fdc6230617d7ea592457dfa580 100644
--- a/content/browser/geolocation/wifi_data_provider_manager.cc
+++ b/content/browser/geolocation/wifi_data_provider_manager.cc
@@ -16,13 +16,13 @@ WifiDataProviderManager::ImplFactoryFunction
WifiDataProviderManager::factory_function_ = DefaultFactoryFunction;
// static
-void WifiDataProviderManager::SetFactory(
+void WifiDataProviderManager::SetFactoryForTesting(
ImplFactoryFunction factory_function_in) {
factory_function_ = factory_function_in;
}
// static
-void WifiDataProviderManager::ResetFactory() {
+void WifiDataProviderManager::ResetFactoryForTesting() {
factory_function_ = DefaultFactoryFunction;
}
@@ -65,12 +65,9 @@ WifiDataProviderManager::WifiDataProviderManager() {
DCHECK(factory_function_);
impl_ = (*factory_function_)();
DCHECK(impl_.get());
- impl_->SetContainer(this);
}
WifiDataProviderManager::~WifiDataProviderManager() {
timvolodine 2014/08/20 16:05:40 does it still need a DCHECK(impl_)?
Michael van Ouwerkerk 2014/08/21 15:46:23 Yes, looks like I was overzealous with the delete
- DCHECK(impl_.get());
- impl_->SetContainer(NULL);
}
bool WifiDataProviderManager::GetData(WifiData* data) {
« no previous file with comments | « content/browser/geolocation/wifi_data_provider_manager.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698