mobile/app
David Crawshaw 5c91e60c93 app: android activity lifecycle awareness
This CL fixes two bugs in the existing app implementation on android.
The first, is it assumed a single NativeActivity instance is created
per process. This is not true. If you open an app, hit the back
button, then open it again, the original activity is destroyed and a
new one is created. So only call main.main in the first onCreate.

The second bug has to do with window lifetimes. Previously we only
processed GL work while the window existed, as part of a paint cycle.
This missed GL events called as part of a lifecycle downgrade when
the window was destroyed. (I.e. the contents of onStop.) This CL
fixes this by making the main android event processing loop last for
the life of the process, not the window.

Fixes golang/go#11804.

Change-Id: Ia03e464aab5bc10ba75564b7ca11054515cda011
Reviewed-on: https://go-review.googlesource.com/12533
Reviewed-by: Nigel Tao <nigeltao@golang.org>
2015-07-29 14:29:11 +00:00
..
internal app: basic android app lifecycle test 2015-07-28 15:24:53 +00:00
GoNativeActivity.java app, cmd/gomobile: subclass NativeActivity 2015-07-13 19:05:26 +00:00
android.c app: android activity lifecycle awareness 2015-07-29 14:29:11 +00:00
android.go app: android activity lifecycle awareness 2015-07-29 14:29:11 +00:00
app.go app: android activity lifecycle awareness 2015-07-29 14:29:11 +00:00
app_test.go app: basic android app lifecycle test 2015-07-28 15:24:53 +00:00
darwin_amd64.go event/config: specify width and height in both pixels and points. 2015-07-28 01:48:05 +00:00
darwin_amd64.m app: use isARepeat method instead of ARepeat prop 2015-07-23 12:08:15 +00:00
darwin_armx.go event/config: specify width and height in both pixels and points. 2015-07-28 01:48:05 +00:00
darwin_armx.m event/touch: rename TypeStart to TypeBegin. 2015-07-18 04:39:45 +00:00
doc.go event/mouse: new package. 2015-07-28 01:28:46 +00:00
loop_android.go app: android activity lifecycle awareness 2015-07-29 14:29:11 +00:00
x11.c event/touch: rename TypeStart to TypeBegin. 2015-07-18 04:39:45 +00:00
x11.go event/config: specify width and height in both pixels and points. 2015-07-28 01:48:05 +00:00