diff --git a/.gitignore b/.gitignore index 4eb8488..8a165bb 100644 --- a/.gitignore +++ b/.gitignore @@ -60,4 +60,5 @@ fastlane/readme.md # Others .DS_Store +hidden_keys.xml diff --git a/build.gradle b/build.gradle index c80ff84..cb69287 100644 --- a/build.gradle +++ b/build.gradle @@ -1,14 +1,14 @@ // Top-level build file where you can add configuration options common to all sub-projects/modules. buildscript { - ext.kotlin_version = '1.3.31' + ext.kotlin_version = '1.3.40' repositories { google() jcenter() } dependencies { - classpath 'com.android.tools.build:gradle:3.4.0' + classpath 'com.android.tools.build:gradle:3.4.1' classpath 'com.google.gms:google-services:4.2.0' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" } diff --git a/library/build.gradle b/library/build.gradle index 3b3f646..7eb7954 100644 --- a/library/build.gradle +++ b/library/build.gradle @@ -38,23 +38,23 @@ dependencies { implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version" // KTX - implementation 'androidx.core:core-ktx:1.1.0-alpha05' + implementation 'androidx.core:core-ktx:1.2.0-alpha02' // Anko Commons implementation "org.jetbrains.anko:anko-commons:0.10.8" // Support library - implementation 'androidx.appcompat:appcompat:1.1.0-alpha04' - implementation 'androidx.constraintlayout:constraintlayout:2.0.0-alpha4' - implementation 'com.google.android.material:material:1.1.0-alpha05' + implementation 'androidx.appcompat:appcompat:1.1.0-beta01' + implementation 'androidx.constraintlayout:constraintlayout:2.0.0-beta2' + implementation 'com.google.android.material:material:1.1.0-alpha07' // Android architecture components - implementation 'androidx.lifecycle:lifecycle-extensions:2.1.0-alpha04' - implementation 'androidx.lifecycle:lifecycle-common-java8:2.1.0-alpha04' + implementation 'androidx.lifecycle:lifecycle-extensions:2.2.0-alpha01' + implementation 'androidx.lifecycle:lifecycle-common-java8:2.2.0-alpha01' // Google Play Services - implementation 'com.google.android.gms:play-services-location:16.0.0' - implementation 'com.google.android.gms:play-services-maps:16.1.0' + implementation 'com.google.android.gms:play-services-location:17.0.0' + implementation 'com.google.android.gms:play-services-maps:17.0.0' implementation 'com.google.android.libraries.places:places:1.1.0' // Koin for Android @@ -62,7 +62,7 @@ dependencies { implementation 'org.koin:koin-android-viewmodel:2.0.0-rc-2' // Rx - implementation 'io.reactivex.rxjava2:rxjava:2.2.4' + implementation 'io.reactivex.rxjava2:rxjava:2.2.7' implementation 'io.reactivex.rxjava2:rxandroid:2.1.0' // Moshi @@ -70,9 +70,9 @@ dependencies { kapt 'com.squareup.moshi:moshi-kotlin-codegen:1.8.0' // Retrofit - implementation 'com.squareup.retrofit2:retrofit:2.5.0' - implementation 'com.squareup.retrofit2:converter-moshi:2.5.0' - implementation 'com.squareup.retrofit2:adapter-rxjava2:2.5.0' + implementation 'com.squareup.retrofit2:retrofit:2.6.0' + implementation 'com.squareup.retrofit2:converter-moshi:2.6.0' + implementation 'com.squareup.retrofit2:adapter-rxjava2:2.6.0' implementation 'com.squareup.okhttp3:logging-interceptor:3.14.1' // Picasso @@ -83,6 +83,6 @@ dependencies { implementation 'com.karumi:dexter:5.0.0' testImplementation 'junit:junit:4.13-beta-2' - androidTestImplementation 'androidx.test:runner:1.2.0-alpha04' - androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0-alpha04' + androidTestImplementation 'androidx.test:runner:1.3.0-alpha01' + androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0-alpha01' } diff --git a/library/src/main/java/com/rtchagas/pingplacepicker/inject/RepositoryModule.kt b/library/src/main/java/com/rtchagas/pingplacepicker/inject/RepositoryModule.kt index 7cefe80..65adf9b 100644 --- a/library/src/main/java/com/rtchagas/pingplacepicker/inject/RepositoryModule.kt +++ b/library/src/main/java/com/rtchagas/pingplacepicker/inject/RepositoryModule.kt @@ -8,6 +8,7 @@ import com.rtchagas.pingplacepicker.repository.googlemaps.GoogleMapsRepository import okhttp3.OkHttpClient import okhttp3.logging.HttpLoggingInterceptor import org.koin.android.ext.koin.androidContext +import org.koin.dsl.bind import org.koin.dsl.module import retrofit2.Retrofit import retrofit2.adapter.rxjava2.RxJava2CallAdapterFactory @@ -40,5 +41,7 @@ val repositoryModule = module { } // GoogleMapsRepository - single { GoogleMapsRepository(googleClient = get(), googleMapsAPI = get()) as PlaceRepository } + single { + GoogleMapsRepository(googleClient = get(), googleMapsAPI = get()) + } bind PlaceRepository::class } \ No newline at end of file diff --git a/library/src/main/java/com/rtchagas/pingplacepicker/viewmodel/BaseViewModel.kt b/library/src/main/java/com/rtchagas/pingplacepicker/viewmodel/BaseViewModel.kt index 24428e5..dfb874f 100644 --- a/library/src/main/java/com/rtchagas/pingplacepicker/viewmodel/BaseViewModel.kt +++ b/library/src/main/java/com/rtchagas/pingplacepicker/viewmodel/BaseViewModel.kt @@ -21,7 +21,7 @@ abstract class BaseViewModel : ViewModel() { compositeDisposable.add(disposable) } - fun clearDisposables() { + private fun clearDisposables() { compositeDisposable.clear() } } diff --git a/sample/build.gradle b/sample/build.gradle index 3b9c8ba..fb709c8 100644 --- a/sample/build.gradle +++ b/sample/build.gradle @@ -42,8 +42,8 @@ dependencies { // Support library implementation 'androidx.appcompat:appcompat:1.1.0-alpha04' - implementation 'androidx.constraintlayout:constraintlayout:2.0.0-alpha4' - implementation 'com.google.android.material:material:1.1.0-alpha05' + implementation 'androidx.constraintlayout:constraintlayout:2.0.0-beta2' + implementation 'com.google.android.material:material:1.1.0-alpha07' // Places library implementation 'com.google.android.libraries.places:places:1.1.0' diff --git a/sample/src/main/res/values/keys.xml b/sample/src/main/res/values/keys.xml index 86c134e..6632707 100644 --- a/sample/src/main/res/values/keys.xml +++ b/sample/src/main/res/values/keys.xml @@ -2,7 +2,7 @@ - Add here an Android restricted key - Add here an Geolocation API only restricted key + @string/key_android + @string/key_geolocation \ No newline at end of file