Skip to content

add notification interceptor for android auto#5778

Merged
Zayankovsky merged 1 commit intomainfrom
vz-android-auto-notification
May 17, 2022
Merged

add notification interceptor for android auto#5778
Zayankovsky merged 1 commit intomainfrom
vz-android-auto-notification

Conversation

@Zayankovsky
Copy link
Copy Markdown
Contributor

Description

Added a notification interceptor, that lets easily set up notifications in Android Auto. Not sure about adding a dependency on :libtrip-notification module, but needed a way to re-use notification resources somehow.

Screenshots or Gifs

Screenshot 2022-05-05 at 19 23 09

Screenshot 2022-05-05 at 19 23 15

There is also an option to show a heads-up notification by setting high importance, but since the notification is updated approximately every two seconds this option should be used only when there is a significant change in the route progress. This and any other extra customization can be applied via CarNotificationInterceptor arguments if needed.

@Zayankovsky Zayankovsky added the Android Auto Bugs, improvements and feature requests on Android Auto. label May 5, 2022
@Zayankovsky Zayankovsky self-assigned this May 5, 2022
@Zayankovsky Zayankovsky requested a review from a team as a code owner May 5, 2022 17:03
Comment thread libnavui-androidauto/build.gradle Outdated
@codecov
Copy link
Copy Markdown

codecov Bot commented May 5, 2022

Codecov Report

Merging #5778 (b122019) into main (55ed13e) will decrease coverage by 0.56%.
The diff coverage is n/a.

❗ Current head b122019 differs from pull request most recent head dd69719. Consider uploading reports for the commit dd69719 to get more accurate results

Impacted file tree graph

@@             Coverage Diff              @@
##               main    #5778      +/-   ##
============================================
- Coverage     67.63%   67.06%   -0.57%     
+ Complexity     3829     3790      -39     
============================================
  Files           586      584       -2     
  Lines         23583    23604      +21     
  Branches       2715     2710       -5     
============================================
- Hits          15951    15831     -120     
- Misses         6614     6767     +153     
+ Partials       1018     1006      -12     
Impacted Files Coverage Δ
...igation/base/internal/maneuver/ManeuverTurnIcon.kt 0.00% <0.00%> (-100.00%) ⬇️
...base/internal/maneuver/ManeuverTypeModifierPair.kt 0.00% <0.00%> (-100.00%) ⬇️
...avigation/base/internal/maneuver/TurnIconHelper.kt 0.00% <0.00%> (-82.71%) ⬇️
...avigation/base/internal/route/NavigationRouteEx.kt 9.09% <0.00%> (-65.91%) ⬇️
...com/mapbox/navigation/core/navigator/LocationEx.kt 77.10% <0.00%> (-12.05%) ⬇️
...ion/core/trip/session/TripSessionLocationEngine.kt 86.11% <0.00%> (-5.56%) ⬇️
...mapbox/navigation/utils/internal/LoggerProvider.kt 55.55% <0.00%> (-1.59%) ⬇️
...ation/core/replay/route/ReplayRouteInterpolator.kt 97.10% <0.00%> (-0.78%) ⬇️
...ation/ui/maps/route/line/api/MapboxRouteLineApi.kt 80.59% <0.00%> (-0.47%) ⬇️
...ui/maps/route/line/model/MapboxRouteLineOptions.kt 83.23% <0.00%> (-0.10%) ⬇️
... and 17 more

@Zayankovsky Zayankovsky force-pushed the vz-android-auto-notification branch 2 times, most recently from 7f9ca2e to 12ad33c Compare May 10, 2022 11:36
@Zayankovsky Zayankovsky force-pushed the vz-android-auto-notification branch 3 times, most recently from 2072a8a to 1f1d700 Compare May 16, 2022 18:06
@kmadsen
Copy link
Copy Markdown
Contributor

kmadsen commented May 16, 2022

Thanks for picking this up! It works great, especially like how it shows the upcoming maneuver while navigating. It also serves as great example of how you can build your own car notification with MapboxNavigationObserver and TripNotificationInterceptor. I left a couple minor comments

Also, thanks for adding @ExperimentalPreviewMapboxNavigationAPI. Let's continue to iterate the details on the main line 🚢

Comment thread libnavui-androidauto/build.gradle Outdated
@Zayankovsky Zayankovsky force-pushed the vz-android-auto-notification branch 2 times, most recently from 3a1cfe9 to 5505c7b Compare May 17, 2022 11:35
@Zayankovsky Zayankovsky force-pushed the vz-android-auto-notification branch from 5505c7b to eaa81e2 Compare May 17, 2022 11:52
@Zayankovsky Zayankovsky enabled auto-merge (squash) May 17, 2022 11:54
@Zayankovsky Zayankovsky merged commit fc8744c into main May 17, 2022
@Zayankovsky Zayankovsky deleted the vz-android-auto-notification branch May 17, 2022 12:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Android Auto Bugs, improvements and feature requests on Android Auto.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants