-
Notifications
You must be signed in to change notification settings - Fork 312
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New car play change colors logic #4620
New car play change colors logic #4620
Conversation
API compatibility report for MapboxNavigation: 🔴Protocol Requirement Change
|
d1d8fae
to
677ceff
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please also add a changelog
Codecov ReportAttention: Patch coverage is
@@ Coverage Diff @@
## release-v2.18 #4620 +/- ##
=================================================
- Coverage 60.54% 60.51% -0.03%
=================================================
Files 189 189
Lines 21297 21307 +10
=================================================
Hits 12894 12894
- Misses 8403 8413 +10
|
primaryManeuver.symbolSet = visualInstruction.primaryInstruction.maneuverImageSet(side: visualInstruction.drivingSide) | ||
} | ||
|
||
primaryManeuver.symbolSet = visualInstruction.primaryInstruction.maneuverImageSet(side: visualInstruction.drivingSide) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for history, some info on why we made this change.
From Apple CarPlay development guide:
If the maneuver has an associated symbol, such as a turn right arrow, provide an image
using symbolSet. [...] You must provide two image variants using CPImageSet—one is used for rendering
the symbol on light backgrounds, the other is used for rendering the symbol on dark backgrounds.
Since we don't know which custom background color a developer might provide, we always use symbolSet
to pass both white and dark symbols for maneuvers, CarPlay will choose a better version on its own.
Sources/MapboxNavigation/CarPlayNavigationViewControllerDelegate.swift
Outdated
Show resolved
Hide resolved
API compatibility report for MapboxNavigation: 🔴Protocol Requirement Change
|
This PR introduce new logic related to configuration to set custom colors to
CPMapTemplate.guidanceBackgroundColor
using new delegate method:CarPlayNavigationViewControllerDelegate.carPlayNavigationViewController(_:guidanceBackgroundColor:)