From c326f15ae4ad6b6f4872529bc4de208c7f66615e Mon Sep 17 00:00:00 2001 From: Bennet Brunsen Date: Fri, 3 Jul 2015 10:43:46 +0200 Subject: [PATCH] Removed unused code in TrackingService --- .../app/services/TrackingService.java | 20 +++---------------- 1 file changed, 3 insertions(+), 17 deletions(-) diff --git a/mobile/com.sap.sailing.android.tracking.app/src/com/sap/sailing/android/tracking/app/services/TrackingService.java b/mobile/com.sap.sailing.android.tracking.app/src/com/sap/sailing/android/tracking/app/services/TrackingService.java index 0ff1a87b2a7..40fedb713ce 100644 --- a/mobile/com.sap.sailing.android.tracking.app/src/com/sap/sailing/android/tracking/app/services/TrackingService.java +++ b/mobile/com.sap.sailing.android.tracking.app/src/com/sap/sailing/android/tracking/app/services/TrackingService.java @@ -114,6 +114,7 @@ public class TrackingService extends Service implements GoogleApiClient.Connecti locationUpdateRequested = true; ExLog.i(this, TAG, "Started Tracking"); + // Useful code for Bug 3048. Will stay commented for now. // showNotification(); prefs.setTrackerIsTracking(true); @@ -209,12 +210,6 @@ public class TrackingService extends Service implements GoogleApiClient.Connecti } catch (JSONException ex) { ExLog.i(this, TAG, "Error while building geolocation json " + ex.getMessage()); } - - // DatabaseHelper.getInstance().insertGPSFix(this, location.getLatitude(), - // location.getLongitude(), location.getSpeed(), - // location.getBearing(), location.getProvider(), - // location.getTime(), eventRowId); - // ensureTransmittingServiceIsRunning(); } /** @@ -262,17 +257,6 @@ public class TrackingService extends Service implements GoogleApiClient.Connecti return batteryPct; } - /** - * start transmitting service when a new fix arrives, because it ends itself, if there's no data to send. - */ - // private void ensureTransmittingServiceIsRunning() { - // if (BuildConfig.DEBUG) { - // ExLog.i(this, TAG, - // "ensureTransmittingServiceIsRunning, starting TransmittingService"); - // } - // - // ServiceHelper.getInstance().startTransmittingService(this); - // } @Override public IBinder onBind(Intent intent) { return trackingBinder; @@ -284,6 +268,8 @@ public class TrackingService extends Service implements GoogleApiClient.Connecti notificationManager.cancel(NOTIFICATION_ID); Toast.makeText(this, R.string.tracker_stopped, Toast.LENGTH_SHORT).show(); } + + // Useful code for Bug 3048. Will stay commented for now. // private void showNotification() { // Intent intent = new Intent(this, RegattaActivity.class);