OLD | NEW |
(Empty) | |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "device/geolocation/geolocation_manager.h" |
| 6 |
| 7 #include "base/bind.h" |
| 8 #include "mojo/public/cpp/bindings/strong_binding.h" |
| 9 |
| 10 namespace device { |
| 11 |
| 12 GeolocationManager::GeolocationManager() {} |
| 13 |
| 14 GeolocationManager::~GeolocationManager() {} |
| 15 |
| 16 // static |
| 17 void GeolocationManager::Create( |
| 18 const service_manager::BindSourceInfo& source_info, |
| 19 mojom::GeolocationManagerRequest request) { |
| 20 mojo::MakeStrongBinding(base::MakeUnique<GeolocationManager>(), |
| 21 std::move(request)); |
| 22 } |
| 23 |
| 24 void GeolocationManager::IsHighAccuracyLocationBeingCaptured( |
| 25 IsHighAccuracyLocationBeingCapturedCallback callback) { |
| 26 bool high_accuracy = |
| 27 GeolocationProvider::GetInstance()->HighAccuracyLocationInUse(); |
| 28 std::move(callback).Run(high_accuracy); |
| 29 return; |
| 30 } |
| 31 |
| 32 } // namespace device |
OLD | NEW |