diff options
author | Bruno de Oliveira Abinader <bruno@mapbox.com> | 2019-03-21 18:36:43 +0200 |
---|---|---|
committer | Bruno de Oliveira Abinader <bruno@mapbox.com> | 2019-03-22 18:54:48 +0200 |
commit | 03db58cdc1f1f31034863020f205f5c5696bfa8b (patch) | |
tree | e4201a14948d3772fbd4f8bcff6f7d38e2dfd27d /platform/android/src/file_source.cpp | |
parent | 2de2b0b068520a55170d23c86f349232b3e28ae7 (diff) | |
download | qtlocation-mapboxgl-03db58cdc1f1f31034863020f205f5c5696bfa8b.tar.gz |
[core] Replace shared_ptr with unique_ptr in {Map,Resource}Options
Diffstat (limited to 'platform/android/src/file_source.cpp')
-rw-r--r-- | platform/android/src/file_source.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/platform/android/src/file_source.cpp b/platform/android/src/file_source.cpp index bb1f30981b..94db563efc 100644 --- a/platform/android/src/file_source.cpp +++ b/platform/android/src/file_source.cpp @@ -31,7 +31,7 @@ FileSource::FileSource(jni::JNIEnv& _env, std::string path = jni::Make<std::string>(_env, _cachePath); mapbox::sqlite::setTempPath(path); - resourceOptions = mbgl::ResourceOptions() + resourceOptions .withAccessToken(accessToken ? jni::Make<std::string>(_env, accessToken) : "") .withCachePath(path + DATABASE_FILE) .withPlatformContext(reinterpret_cast<void*>(new AssetManagerFileSource(_env, assetManager))); @@ -120,7 +120,7 @@ FileSource* FileSource::getNativePeer(jni::JNIEnv& env, const jni::Object<FileSo mbgl::ResourceOptions FileSource::getSharedResourceOptions(jni::JNIEnv& env, const jni::Object<FileSource>& jFileSource) { FileSource* fileSource = FileSource::getNativePeer(env, jFileSource); assert(fileSource != nullptr); - return fileSource->resourceOptions; + return mbgl::ResourceOptions(fileSource->resourceOptions); } void FileSource::registerNative(jni::JNIEnv& env) { |