Only Android API < 11 needs o set the surface type.

Change-Id: I290d7273624ce4853a137c00263fa9a169ea0cf9
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
This commit is contained in:
BogDan Vatra 2014-01-30 11:42:52 +02:00 committed by The Qt Project
parent fc43748893
commit 6fe4deca3f

View File

@ -67,7 +67,9 @@ public class QtSurface extends SurfaceView implements SurfaceHolder.Callback
setZOrderMediaOverlay(onTop);
getHolder().addCallback(this);
getHolder().setFormat(PixelFormat.RGBA_8888);
getHolder().setType(SurfaceHolder.SURFACE_TYPE_GPU);
if (android.os.Build.VERSION.SDK_INT < 11)
getHolder().setType(SurfaceHolder.SURFACE_TYPE_GPU);
setId(id);
m_gestureDetector =
new GestureDetector(context, new GestureDetector.SimpleOnGestureListener() {