package org.edx.mobile.player; import android.content.Context; import android.graphics.Color; import android.graphics.SurfaceTexture; import android.util.AttributeSet; import android.view.SurfaceHolder; import android.view.SurfaceHolder.Callback; import android.view.TextureView; public class Preview extends TextureView implements TextureView.SurfaceTextureListener { public Preview(Context context) { super(context); init(); } public Preview(Context context, AttributeSet attrs) { super(context, attrs); init(); } public Preview(Context context, AttributeSet attrs, int defStyle) { super(context, attrs, defStyle); init(); } private void init() { setSurfaceTextureListener(this); } @Override public void onSurfaceTextureAvailable(SurfaceTexture surface, int width, int height) { } @Override public void onSurfaceTextureSizeChanged(SurfaceTexture surface, int width, int height) { } @Override public boolean onSurfaceTextureDestroyed(SurfaceTexture surface) { return false; } @Override public void onSurfaceTextureUpdated(SurfaceTexture surface) { } }