Bug 801627 - Fix fullscreen Flash on Android r=blassey

This commit is contained in:
James Willcox 2012-10-22 10:51:29 -04:00
parent 74bc9298a3
commit e4a3bbc361
2 changed files with 14 additions and 4 deletions

View File

@ -1357,15 +1357,15 @@ abstract public class GeckoApp
// We need do do this on the next iteration in order to avoid
// a deadlock, see comment below in FullScreenHolder
mMainHandler.post(new Runnable() {
mMainHandler.post(new Runnable() {
public void run() {
mLayerView.setVisibility(View.VISIBLE);
mLayerView.show();
}
});
FrameLayout decor = (FrameLayout)getWindow().getDecorView();
decor.removeView(mFullScreenPluginContainer);
mFullScreenPluginView = null;
GeckoScreenOrientationListener.getInstance().unlockScreenOrientation();
@ -2651,7 +2651,7 @@ abstract public class GeckoApp
mMainHandler.post(new Runnable() {
public void run() {
mLayerView.setVisibility(View.INVISIBLE);
mLayerView.hide();
}
});
}

View File

@ -110,6 +110,16 @@ public class LayerView extends FrameLayout {
GeckoAccessibility.setDelegate(this);
}
public void show() {
// Fix this if TextureView support is turned back on above
mSurfaceView.setVisibility(View.VISIBLE);
}
public void hide() {
// Fix this if TextureView support is turned back on above
mSurfaceView.setVisibility(View.INVISIBLE);
}
public void destroy() {
if (mLayerClient != null) {
mLayerClient.destroy();