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

Commit a4248f69 authored by Teng-Hui Zhu's avatar Teng-Hui Zhu Committed by Android (Google) Code Review
Browse files

Merge "Don't sleep when inline video start"

parents f5ad309a 690ad540
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -7,6 +7,7 @@ import android.webkit.HTML5VideoView;
import android.webkit.HTML5VideoViewProxy;
import android.view.Surface;
import android.opengl.GLES20;
import android.os.PowerManager;

/**
 * @hide This is only used by the browser
@@ -51,6 +52,7 @@ public class HTML5VideoInline extends HTML5VideoView{
    public void prepareDataAndDisplayMode(HTML5VideoViewProxy proxy) {
        super.prepareDataAndDisplayMode(proxy);
        setFrameAvailableListener(proxy);
        mPlayer.setWakeMode(proxy.getContext(), PowerManager.FULL_WAKE_LOCK);
    }

    // Pause the play and update the play/pause button