summaryrefslogtreecommitdiffstats
path: root/chrome/browser/geolocation/empty_device_data_provider.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/geolocation/empty_device_data_provider.cc')
-rw-r--r--chrome/browser/geolocation/empty_device_data_provider.cc22
1 files changed, 22 insertions, 0 deletions
diff --git a/chrome/browser/geolocation/empty_device_data_provider.cc b/chrome/browser/geolocation/empty_device_data_provider.cc
new file mode 100644
index 0000000..9e9fc27
--- /dev/null
+++ b/chrome/browser/geolocation/empty_device_data_provider.cc
@@ -0,0 +1,22 @@
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "chrome/browser/geolocation/empty_device_data_provider.h"
+
+// No platform has (cellular) radio data provider yet.
+// static
+template<>
+RadioDataProviderImplBase* RadioDataProvider::DefaultFactoryFunction() {
+ return new EmptyDeviceDataProvider<RadioData>();
+}
+
+// Only define for platforms that lack a real wifi data provider.
+#if !defined(OS_WIN) && !defined(OS_MACOSX) && !defined(OS_LINUX)
+// static
+template<>
+WifiDataProviderImplBase* WifiDataProvider::DefaultFactoryFunction() {
+ return new EmptyDeviceDataProvider<WifiData>();
+}
+#endif
+