summaryrefslogtreecommitdiff
path: root/platform/android/src/map_renderer.hpp
diff options
context:
space:
mode:
authorIvo van Dongen <info@ivovandongen.nl>2019-02-14 11:12:02 +0200
committerIvo van Dongen <ivovandongen@users.noreply.github.com>2019-02-14 13:58:03 +0200
commit3802f7e922e16a18c75d66aa615094f4c62fd0b1 (patch)
tree1c3e74fcaf47ff42a023503a28503051aef11aa0 /platform/android/src/map_renderer.hpp
parentceea900578d8f31497810ef19aa7c17669e40722 (diff)
downloadqtlocation-mapboxgl-3802f7e922e16a18c75d66aa615094f4c62fd0b1.tar.gz
[android] hook into surface holder to cleanup renderer on the right thread before the surface is destroyed
Diffstat (limited to 'platform/android/src/map_renderer.hpp')
-rw-r--r--platform/android/src/map_renderer.hpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/platform/android/src/map_renderer.hpp b/platform/android/src/map_renderer.hpp
index d60447e0ec..8c2f28a4df 100644
--- a/platform/android/src/map_renderer.hpp
+++ b/platform/android/src/map_renderer.hpp
@@ -94,6 +94,9 @@ private:
void onSurfaceChanged(JNIEnv&, jint width, jint height);
+ // Called on Main thread
+ void onSurfaceDestroyed(JNIEnv&);
+
private:
jni::WeakReference<jni::Object<MapRenderer>, jni::EnvAttachingDeleter> javaPeer;