Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Commit

Permalink
[android] - add library loading to peer objects
Browse files Browse the repository at this point in the history
  • Loading branch information
tobrun committed Jan 17, 2019
1 parent 9a76621 commit 16718b0
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import android.support.annotation.Nullable;

import com.google.gson.JsonElement;
import com.mapbox.mapboxsdk.LibraryLoader;
import com.mapbox.mapboxsdk.style.expressions.Expression;
import com.mapbox.mapboxsdk.style.types.Formatted;
import com.mapbox.mapboxsdk.utils.ThreadUtils;
Expand All @@ -20,6 +21,10 @@ public abstract class Layer {
private boolean invalidated;
private boolean detached;

static {
LibraryLoader.load();
}

@Keep
protected Layer(long nativePtr) {
checkThread();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
import android.support.annotation.Keep;

import android.support.annotation.NonNull;

import com.mapbox.mapboxsdk.LibraryLoader;
import com.mapbox.mapboxsdk.utils.ThreadUtils;

/**
Expand All @@ -15,6 +17,10 @@ public abstract class Source {

protected boolean detached;

static {
LibraryLoader.load();
}

/**
* Internal use
*
Expand Down

0 comments on commit 16718b0

Please sign in to comment.