summaryrefslogtreecommitdiff
path: root/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshot.java
diff options
context:
space:
mode:
authorŁukasz Paczos <lukas.paczos@gmail.com>2018-07-24 00:20:02 +0200
committerŁukasz Paczos <lukasz.paczos@mapbox.com>2018-07-26 19:47:11 +0200
commit94ad8e2ff8928bec316dfcc9790db7b522673d3e (patch)
tree1a7b0c7fb42aa6dba049c5d42305f6d5c4ac93b7 /platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshot.java
parent5fcd6e38a9e9ca755d997b83f007f8a2f435cf45 (diff)
downloadqtlocation-mapboxgl-94ad8e2ff8928bec316dfcc9790db7b522673d3e.tar.gz
[android] using @Keep annotation across the project with the help of lint checks
Diffstat (limited to 'platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshot.java')
-rw-r--r--platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshot.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshot.java b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshot.java
index 0dbf977e4e..f3acf829bf 100644
--- a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshot.java
+++ b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/snapshotter/MapSnapshot.java
@@ -2,6 +2,7 @@ package com.mapbox.mapboxsdk.snapshotter;
import android.graphics.Bitmap;
import android.graphics.PointF;
+import android.support.annotation.Keep;
import com.mapbox.mapboxsdk.geometry.LatLng;
@@ -12,6 +13,7 @@ import com.mapbox.mapboxsdk.geometry.LatLng;
*/
public class MapSnapshot {
+ @Keep
private long nativePtr = 0;
private Bitmap bitmap;
private String[] attributions;
@@ -20,6 +22,7 @@ public class MapSnapshot {
/**
* Created from native side
*/
+ @Keep
private MapSnapshot(long nativePtr, Bitmap bitmap, String[] attributions, boolean showLogo) {
this.nativePtr = nativePtr;
this.bitmap = bitmap;
@@ -40,6 +43,7 @@ public class MapSnapshot {
* @param latLng the geographical coordinates
* @return the point on the image
*/
+ @Keep
public native PointF pixelForLatLng(LatLng latLng);
/**
@@ -48,6 +52,7 @@ public class MapSnapshot {
* @param pointF the point in pixels
* @return the geographical coordinates
*/
+ @Keep
public native LatLng latLngForPixel(PointF pointF);
/**
@@ -65,7 +70,9 @@ public class MapSnapshot {
}
// Unused, needed for peer binding
+ @Keep
private native void initialize();
+ @Keep
protected native void finalize();
}