From 0504967cb05f7bbd0c17962360a5d88ace8d173f Mon Sep 17 00:00:00 2001 From: Teng-Hui Zhu Date: Wed, 6 Apr 2011 18:09:27 -0700 Subject: Fix the issue the video can't start to play In full screen mode, we shall not always rely on the auto start info. If the auto start is false, it will prevent the video from playing. The auto start should always happen inline mode when prepared. If we switch into full screen mode while playing, we will also do auto start. bug:4260063 Change-Id: I4b13c30b1f2c219951dc8edd659e221a21c86c2b --- core/java/android/webkit/HTML5VideoViewProxy.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'core/java/android/webkit/HTML5VideoViewProxy.java') diff --git a/core/java/android/webkit/HTML5VideoViewProxy.java b/core/java/android/webkit/HTML5VideoViewProxy.java index acd7eab63a48..c7270299bec0 100644 --- a/core/java/android/webkit/HTML5VideoViewProxy.java +++ b/core/java/android/webkit/HTML5VideoViewProxy.java @@ -224,8 +224,9 @@ class HTML5VideoViewProxy extends Handler } public static void onPrepared() { - // The VideoView will decide whether to really kick off to play. - mHTML5VideoView.start(); + if (!mHTML5VideoView.isFullScreenMode() || mHTML5VideoView.getAutostart()) { + mHTML5VideoView.start(); + } if (mBaseLayer != 0) { setBaseLayer(mBaseLayer); } -- cgit v1.2.3