GPS: Don't set XTRA download pending flag at boot time.
XTRA data downloads are now strictly on demand from the GPS engine. Also fix typo in handleDownloadXtraData() Change-Id: Ied1a6e2e62134add4d965326aae909c86f834682 Signed-off-by: Mike Lockwood <lockwood@android.com>
This commit is contained in:
@@ -177,7 +177,7 @@ public class GpsLocationProvider implements LocationProviderInterface {
|
|||||||
// flags to trigger NTP or XTRA data download when network becomes available
|
// flags to trigger NTP or XTRA data download when network becomes available
|
||||||
// initialized to true so we do NTP and XTRA when the network comes up after booting
|
// initialized to true so we do NTP and XTRA when the network comes up after booting
|
||||||
private boolean mInjectNtpTimePending = true;
|
private boolean mInjectNtpTimePending = true;
|
||||||
private boolean mDownloadXtraDataPending = true;
|
private boolean mDownloadXtraDataPending = false;
|
||||||
|
|
||||||
// true if GPS is navigating
|
// true if GPS is navigating
|
||||||
private boolean mNavigating;
|
private boolean mNavigating;
|
||||||
@@ -495,7 +495,7 @@ public class GpsLocationProvider implements LocationProviderInterface {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void handleDownloadXtraData() {
|
private void handleDownloadXtraData() {
|
||||||
if (!mDownloadXtraDataPending) {
|
if (!mNetworkAvailable) {
|
||||||
// try again when network is up
|
// try again when network is up
|
||||||
mDownloadXtraDataPending = true;
|
mDownloadXtraDataPending = true;
|
||||||
return;
|
return;
|
||||||
|
|||||||
Reference in New Issue
Block a user