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

Side by Side Diff: content/browser/geolocation/wifi_data_provider_linux.cc

Issue 10535157: [WIP] attempt to allow chrome OS to inject its wifi data provider (Closed) Base URL: http://git.chromium.org/chromium/src.git@remove_radio
Patch Set: 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 unified diff | Download patch
OLDNEW
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 // Provides wifi scan API binding for suitable for typical linux distributions. 5 // Provides wifi scan API binding for suitable for typical linux distributions.
6 // Currently, only the NetworkManager API is used, accessed via D-Bus (in turn 6 // Currently, only the NetworkManager API is used, accessed via D-Bus (in turn
7 // accessed via the GLib wrapper). 7 // accessed via the GLib wrapper).
8 8
9 #include "content/browser/geolocation/wifi_data_provider_linux.h" 9 #include "content/browser/geolocation/wifi_data_provider_linux.h"
10 10
(...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after
335 dbus::ObjectProxy::TIMEOUT_USE_DEFAULT); 335 dbus::ObjectProxy::TIMEOUT_USE_DEFAULT);
336 if (!response) { 336 if (!response) {
337 LOG(WARNING) << "Failed to get property for " << property_name; 337 LOG(WARNING) << "Failed to get property for " << property_name;
338 } 338 }
339 return response; 339 return response;
340 } 340 }
341 341
342 } // namespace 342 } // namespace
343 343
344 // static 344 // static
345 template<>
346 WifiDataProviderImplBase* WifiDataProvider::DefaultFactoryFunction() { 345 WifiDataProviderImplBase* WifiDataProvider::DefaultFactoryFunction() {
347 return new WifiDataProviderLinux(); 346 return new WifiDataProviderLinux();
348 } 347 }
349 348
350 WifiDataProviderLinux::WifiDataProviderLinux() { 349 WifiDataProviderLinux::WifiDataProviderLinux() {
351 } 350 }
352 351
353 WifiDataProviderLinux::~WifiDataProviderLinux() { 352 WifiDataProviderLinux::~WifiDataProviderLinux() {
354 } 353 }
355 354
(...skipping 12 matching lines...) Expand all
368 kNoWifiPollingIntervalMilliseconds>; 367 kNoWifiPollingIntervalMilliseconds>;
369 } 368 }
370 369
371 WifiDataProviderCommon::WlanApiInterface* 370 WifiDataProviderCommon::WlanApiInterface*
372 WifiDataProviderLinux::NewWlanApiForTesting(dbus::Bus* bus) { 371 WifiDataProviderLinux::NewWlanApiForTesting(dbus::Bus* bus) {
373 scoped_ptr<NetworkManagerWlanApi> wlan_api(new NetworkManagerWlanApi); 372 scoped_ptr<NetworkManagerWlanApi> wlan_api(new NetworkManagerWlanApi);
374 if (wlan_api->InitWithBus(bus)) 373 if (wlan_api->InitWithBus(bus))
375 return wlan_api.release(); 374 return wlan_api.release();
376 return NULL; 375 return NULL;
377 } 376 }
OLDNEW
« no previous file with comments | « content/browser/geolocation/wifi_data_provider_common_win.cc ('k') | content/browser/geolocation/wifi_data_provider_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698