Skip to content

Play, pause and play from the beginning in swiftui (bug with playback reset) #2580

@gerchicov-vg

Description

@gerchicov-vg

I have read your article:
#2189

In my particular case I have a button which works as "pause" and "restart play from the beginning" (depending on playback state).

According to your article I should switch between states:

  • .paused
  • .playing(.fromProgress(0, toProgress: 1, loopMode: .loop))

Instead of resetting to start it continues playback from the paused position.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions