File tree Expand file tree Collapse file tree
Sources/MapboxNavigationCore/VoiceGuidance/RemoteSpeechSynthesizer Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11# Changes to the Mapbox Navigation SDK for iOS
22
3+ ## 3.24.0
4+
5+ ### Audio
6+
7+ * Fixed a possible hang during ` MapboxSpeechSynthesizer ` initialization.
8+
39## 3.24.0-rc.1
410
511### Packaging
612
713* MapboxNavigationCore now requires [ MapboxMaps v11.24.0-rc.1] ( https://github.com/mapbox/mapbox-maps-ios/releases/tag/v11.24.0-rc.1 )
814* MapboxNavigationCore now requires [ MapboxNavigationNative v324.24.0-rc.1] ( https://github.com/mapbox/mapbox-navigation-native-ios/releases/tag/v324.24.0-rc.1 )
915
16+ ### Map
17+
18+ * Fixed an issue where panning on the Mapbox map logo or info button could set the navigation camera to the idle state.
19+
1020### Routing
1121
1222* Fixed a race condition that could lead to a crash in ` FasterRouteController ` .
Original file line number Diff line number Diff line change @@ -49,12 +49,17 @@ public final class MapboxSpeechSynthesizer: SpeechSynthesizing {
4949 private func subscribeToSystemVolume( ) {
5050 audioPlayerQueue. async { [ weak audioPlayer] in
5151 guard let audioPlayer else { return }
52- let systemVolume = AVAudioSession . sharedInstance ( ) . outputVolume
52+ let session = AVAudioSession . sharedInstance ( )
53+ let systemVolume = session. outputVolume
5354 audioPlayer. volume = systemVolume
54- }
55- volumeSubscribtion = AVAudioSession . sharedInstance ( ) . publisher ( for: \. outputVolume) . sink { [ weak self] volume in
56- self ? . audioPlayerQueue. async { [ weak audioPlayer = self ? . audioPlayer] in
57- audioPlayer? . volume = volume
55+
56+ let subscription = session. publisher ( for: \. outputVolume)
57+ . receive ( on: self . audioPlayerQueue)
58+ . sink { [ weak audioPlayer] volume in
59+ audioPlayer? . volume = volume
60+ }
61+ onMainAsync { [ weak self] in
62+ self ? . volumeSubscribtion = subscription
5863 }
5964 }
6065 }
You can’t perform that action at this time.
0 commit comments