Hi,

I have an app wich is is a TabActivity with 3 tabs.
Each tab is an activity.

The first tab (Activity1) has a FrameLayout which contains a
GLSurfaceView. All the GL code is done in my native library (using the
ndk)/
I have put logs into the onSurfaceDestroyed (in GLSurfaceView) and the
onSurfaceCreated (in the renderer of the GLSurfaceView) methods to
know when they are called

I launch the app, the first tab (Activity1) is displayed, my GL stuff
works fine.
I switch to the second tab, Activity1 receives the onPause event, so i
call the GLSurfaceView.onPause to pause the glThread. That's works.

I 'm in the second tab, i re-switch in the first tab. Activity1
receives the onResume event, so i call the GLSurfaceView.onResume but
i see in my logs that onSurfaceCreated is called .... and i have never
seen "onSurfaceDestroyed" in logs ...

If I don't call the GLSurfaceView.onPause/onResume, the switch/re-
switch works but onDrawFrame is always called.
Of course, i can use a boolean to draw nothing when the activity is
paused but the onDrawFrame is always called and official doc
recommends to call the GLSurfaceView.onPause/onResume methods.

Any ideas about that?

-- 
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+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to