Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9059f44f authored by Ben Murdoch's avatar Ben Murdoch
Browse files

Make audio tag cope with live streams

Live streams seem to take a little while to initialize, so it's feasible
that we might get a play request before transitioned to the PREPARED
state. In that case track that we should start playing when onPrepare
completes.

Change-Id: I66ed0ef3a0905a1c5d4206fb2e7bbcc05a593fc7
parent 3f98f7bd
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -179,7 +179,7 @@ class HTML5Audio extends Handler
    }

    private void play() {
        if ((mState == ERROR || mState == IDLE) && mUrl != null) {
        if ((mState >= ERROR && mState < PREPARED) && mUrl != null) {
            resetMediaPlayer();
            setDataSource(mUrl);
            mAskToPlay = true;