Did you get any further with this? currently I'm just resizing the size of
the videoview...
Here's what I have so far. But I have a problem, in that when I call this
too often, nothing happens. I want to use it to "animate" the videoview
growing and shrinking...
public class MyVideoView extends VideoView {
protected int _overrideWidth =320;
protected int _overrideHeight =240;
public CupVideoView(Context context){
super(context);
}
public void resizeVideo(int width,int height){
_overrideHeight = height;
_overrideWidth = width;
// not sure whether it is useful or not but safe to do so
getHolder().setFixedSize(width, height);
requestLayout();
invalidate(); // very important, so that onMeasure will be
triggered
}
@Override
protected void onMeasure (int widthMeasureSpec, int heightMeasureSpec)
{
setMeasuredDimension(_overrideWidth,_overrideHeight);
}
}
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en