Skip to content

Commit

Permalink
Let notification say (home) when at home.
Browse files Browse the repository at this point in the history
  • Loading branch information
voussoir committed Apr 6, 2023
1 parent 540f095 commit c722e7c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion app/src/main/java/net/voussoir/trkpt/TrackerService.kt
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,12 @@ class TrackerService: Service()
if (trackingState == Keys.STATE_TRACKING_ACTIVE)
{
notification_builder.setContentTitle(this.getString(R.string.notification_title_trackbook_running))
if (location_interval == Keys.LOCATION_INTERVAL_FULL_POWER)
if (location_interval == Keys.LOCATION_INTERVAL_FULL_POWER && arrived_at_home > 0)
{
notification_builder.setContentTitle("${timestamp} (home)")
notification_builder.setSmallIcon(R.drawable.ic_satellite_24dp)
}
else if (location_interval == Keys.LOCATION_INTERVAL_FULL_POWER)
{
notification_builder.setContentTitle("${timestamp} (recording)")
notification_builder.setSmallIcon(R.drawable.ic_satellite_24dp)
Expand Down

0 comments on commit c722e7c

Please sign in to comment.