OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 // Defines a variant of libgps wrapper for use with the 2.94 release of the API. | 5 // Defines a variant of libgps wrapper for use with the 2.94 release of the API. |
6 | 6 |
7 #include "content/browser/geolocation/libgps_wrapper_linux.h" | 7 #include "content/browser/geolocation/libgps_wrapper_linux.h" |
8 | 8 |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "chrome/common/geoposition.h" | 10 #include "content/common/geoposition.h" |
11 #include "third_party/gpsd/release-2.94/gps.h" | 11 #include "third_party/gpsd/release-2.94/gps.h" |
12 | 12 |
13 class LibGpsV294 : public LibGps { | 13 class LibGpsV294 : public LibGps { |
14 public: | 14 public: |
15 explicit LibGpsV294(LibGpsLibraryWrapper* dl_wrapper) : LibGps(dl_wrapper) {} | 15 explicit LibGpsV294(LibGpsLibraryWrapper* dl_wrapper) : LibGps(dl_wrapper) {} |
16 | 16 |
17 // LibGps | 17 // LibGps |
18 virtual bool StartStreaming() { | 18 virtual bool StartStreaming() { |
19 return library().stream(WATCH_ENABLE) == 0; | 19 return library().stream(WATCH_ENABLE) == 0; |
20 } | 20 } |
(...skipping 18 matching lines...) Expand all Loading... |
39 return true; | 39 return true; |
40 } | 40 } |
41 | 41 |
42 private: | 42 private: |
43 DISALLOW_COPY_AND_ASSIGN(LibGpsV294); | 43 DISALLOW_COPY_AND_ASSIGN(LibGpsV294); |
44 }; | 44 }; |
45 | 45 |
46 LibGps* LibGps::NewV294(LibGpsLibraryWrapper* dl_wrapper) { | 46 LibGps* LibGps::NewV294(LibGpsLibraryWrapper* dl_wrapper) { |
47 return new LibGpsV294(dl_wrapper); | 47 return new LibGpsV294(dl_wrapper); |
48 } | 48 } |
OLD | NEW |