summaryrefslogtreecommitdiff
path: root/android/2.0
diff options
context:
space:
mode:
authorYingjie Wang <yingjiewang@codeaurora.org>2019-10-14 18:21:15 +0800
committerGerrit - the friendly Code Review server <code-review@localhost>2019-10-29 22:03:30 -0700
commitae1d9031eff622838da1596737d871c16dcc9e2e (patch)
tree4fa5113ea3f61b537cb5eabbf082b5c694199300 /android/2.0
parent5c568ca1bdd64c4de4a29695457db6bd81d0f5d8 (diff)
downloadgps-ae1d9031eff622838da1596737d871c16dcc9e2e.tar.gz
Add listener for the initial battery status
Listen to the initial charging status as DPO mode depends on it; Change ALOG to LOC_LOG. Change-Id: Ic61f76038f0e464b18ade8c9b20c058de35748c8 CRs-fixed: 2544828
Diffstat (limited to 'android/2.0')
-rw-r--r--android/2.0/Gnss.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/android/2.0/Gnss.cpp b/android/2.0/Gnss.cpp
index af76b72..2276c14 100644
--- a/android/2.0/Gnss.cpp
+++ b/android/2.0/Gnss.cpp
@@ -96,6 +96,8 @@ void location_on_battery_status_changed(bool charging) {
Gnss::Gnss() {
ENTRY_LOG_CALLFLOW();
sGnss = this;
+ // initilize gnss interface at first in case needing notify battery status
+ sGnss->getGnssInterface()->initialize();
// register health client to listen on battery change
loc_extn_battery_properties_listener_init(location_on_battery_status_changed);
// clear pending GnssConfig