libgdx/libgdx — pull request #128 by acoppes (2012-11-27 14:38:39+00:00)
Title: Fix for issue 1045 - LWP - app.destroy() / memory leaks

Changed AndroidLiveWallpaper to not call graphics.destroy() on onDestroy() method to avoid the deadlock on AndroidGraphicsLiveWallpaper.destroy() which was waiting for graphics.OnDrawFrame() to be called and that was never called again since the surface was destroyed. Added also listener.dispose() before calling app.destryo() since nobody will call it otherwise (it was being called by graphics.onDrawFrame().

Probably not the best solution but I believe that is the real problem when calling app.destroy() which was causing problems.

The idea is to try to fix issue http://code.google.com/p/libgdx/issues/detail?id=1132.