mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 21:33:26 +00:00
Add deferred spinner for voice messages (#2018)
* Add delayedLoaderPlaybackState * Add more tests * Fix Xcode 14 build error * Refactor delayedLoaderPlaybackState -> playerButtonPlaybackState * Fix runtime issue
This commit is contained in:
@@ -88,13 +88,13 @@ private struct VoiceMessageButtonStyle: ButtonStyle {
|
||||
}
|
||||
|
||||
extension VoiceMessageButton.State {
|
||||
init(state: AudioPlayerPlaybackState) {
|
||||
init(_ state: AudioPlayerPlaybackState) {
|
||||
switch state {
|
||||
case .loading:
|
||||
self = .loading
|
||||
case .playing:
|
||||
self = .playing
|
||||
default:
|
||||
case .stopped, .error, .readyToPlay:
|
||||
self = .paused
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user