Skip to content

Instantly share code, notes, and snippets.

@mizutori
Created January 6, 2019 13:14
Show Gist options
  • Save mizutori/793f1222bf389a61733edace80abb621 to your computer and use it in GitHub Desktop.
Save mizutori/793f1222bf389a61733edace80abb621 to your computer and use it in GitHub Desktop.
override fun onLocationChanged(newLocation: Location?) {
newLocation?.let{
Log.d(LOG_TAG, "(" + it.latitude + "," + it.longitude + ")")
gpsCount++
if (isLogging) {
//locationList.add(newLocation);
filterAndAddLocation(it)
}
val intent = Intent("LocationUpdated")
intent.putExtra("location", it)
LocalBroadcastManager.getInstance(this.application).sendBroadcast(intent)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment