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

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

Issue 10534120: Remove RadioData from geolocation (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: fix content_unittests Created 8 years, 6 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
Index: content/browser/geolocation/device_data_provider.cc
diff --git a/content/browser/geolocation/device_data_provider.cc b/content/browser/geolocation/device_data_provider.cc
index 76a8ef3b66d0c8f24587f56c623b8c50d1463750..dc17ee555be6ef632b9937ea304dd8311d98fc5b 100644
--- a/content/browser/geolocation/device_data_provider.cc
+++ b/content/browser/geolocation/device_data_provider.cc
@@ -5,55 +5,11 @@
#include "content/browser/geolocation/device_data_provider.h"
// statics
-template<> DeviceDataProvider<RadioData>*
- DeviceDataProvider<RadioData>::instance_ = NULL;
-template<> DeviceDataProvider<RadioData>::ImplFactoryFunction
- DeviceDataProvider<RadioData>::factory_function_ = DefaultFactoryFunction;
template<> DeviceDataProvider<WifiData>*
DeviceDataProvider<WifiData>::instance_ = NULL;
template<> DeviceDataProvider<WifiData>::ImplFactoryFunction
DeviceDataProvider<WifiData>::factory_function_ = DefaultFactoryFunction;
-namespace {
-
-bool CellDataMatches(const CellData &data1, const CellData &data2) {
- return data1.Matches(data2);
-}
-
-} // namespace
-
-CellData::CellData()
- : cell_id(kint32min),
- location_area_code(kint32min),
- mobile_network_code(kint32min),
- mobile_country_code(kint32min),
- radio_signal_strength(kint32min),
- timing_advance(kint32min) {
-}
-
-RadioData::RadioData()
- : home_mobile_network_code(kint32min),
- home_mobile_country_code(kint32min),
- radio_type(RADIO_TYPE_UNKNOWN) {
-}
-
-RadioData::~RadioData() {}
-
-bool RadioData::Matches(const RadioData &other) const {
- if (cell_data.size() != other.cell_data.size()) {
- return false;
- }
- if (!std::equal(cell_data.begin(), cell_data.end(), other.cell_data.begin(),
- CellDataMatches)) {
- return false;
- }
- return device_id == other.device_id &&
- home_mobile_network_code == other.home_mobile_network_code &&
- home_mobile_country_code == other.home_mobile_country_code &&
- radio_type == other.radio_type &&
- carrier == other.carrier;
-}
-
AccessPointData::AccessPointData()
: radio_signal_strength(kint32min),
channel(kint32min),
« no previous file with comments | « content/browser/geolocation/device_data_provider.h ('k') | content/browser/geolocation/empty_device_data_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698