[android-developers] Re: SurfaceHolder.Callback.surfaceCreated not being triggered when surface is re-created
On Nov 29, 1:29 am, tobias <ecker...@gmx.de> wrote:
> Had exactly the same problem. As it looks like, the issue is not that
> the callback isn't fired, but that when Android creates a new
> SurfaceView, it also creates a new holder. Check if this helps you:http://groups.google.com/group/android-developers/browse_thread/threa...
Thanks for the reply. Here's what I currently do when creating the new
SurfaceView:
surface = new MySurface(getApplicationContext());
SurfaceHolder holder = surface.getHolder();
holder.addCallback(surface);
holder.setType(SurfaceHolder.SURFACE_TYPE_GPU);
setContentView(surface);
So it doesn't look like I'm keeping the holder around, at least it
shouldn't unless somehow Android is pointing to the wrong one when
creating a new SurfaceView.
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home