Skip to content

Commit

Permalink
feat: Upgrade Depend Version
Browse files Browse the repository at this point in the history
  • Loading branch information
biezhihua committed Mar 7, 2019
1 parent 2868647 commit 2c14c45
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 95 deletions.
13 changes: 6 additions & 7 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@ android {
abortOnError false
}

// lintOptions {
// lintConfig rootProject.file('lint.xml')
// }
lintOptions {
lintConfig rootProject.file('lint.xml')
}

dataBinding {
enabled = true
Expand Down Expand Up @@ -133,9 +133,9 @@ dependencies {
implementation 'com.squareup.retrofit2:converter-gson:2.3.0'

//
implementation 'com.google.dagger:dagger:2.15'
implementation 'com.google.dagger:dagger-android:2.15'
implementation 'com.google.dagger:dagger-android-support:2.15'
implementation 'com.google.dagger:dagger:2.17'
implementation 'com.google.dagger:dagger-android:2.17'
implementation 'com.google.dagger:dagger-android-support:2.17'

implementation 'com.github.bumptech.glide:glide:4.9.0'

Expand All @@ -151,7 +151,6 @@ dependencies {
implementation "android.arch.navigation:navigation-ui:1.0.0-rc02" // use -ktx for Kotlin

// java
testImplementation 'com.android.tools.lint:lint-api:26.3.1'
testImplementation 'junit:junit:4.12'
testImplementation 'org.mockito:mockito-core:2.22.0'
testImplementation 'org.hamcrest:hamcrest-all:1.3'
Expand Down
1 change: 1 addition & 0 deletions app/src/main/java/com/bzh/dytt/base/BasicApp.kt
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ class BasicApp : Application(), HasActivityInjector {
Log.d(TAG, "onCreate() called ${getSignature(this)}")
}

@Suppress("DEPRECATION")
@SuppressLint("WrongConstant", "PackageManagerGetSignatures")
private fun getSignature(context: Context): String = if (Build.VERSION.SDK_INT >= 28) {
val packageInfo = context.packageManager.getPackageInfo(context.packageName, PackageManager.GET_SIGNING_CERTIFICATES)
Expand Down
3 changes: 2 additions & 1 deletion app/src/main/java/com/bzh/dytt/di/AppComponent.kt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import com.bzh.dytt.base.BasicApp
import dagger.BindsInstance
import dagger.Component
import dagger.android.AndroidInjectionModule
import dagger.android.support.AndroidSupportInjectionModule
import javax.inject.Singleton


Expand All @@ -16,7 +17,7 @@ import javax.inject.Singleton
* http://a.codekk.com/detail/Android/%E6%89%94%E7%89%A9%E7%BA%BF/Dagger%20%E6%BA%90%E7%A0%81%E8%A7%A3%E6%9E%90
*/
@Singleton
@Component(modules = [AndroidInjectionModule::class, MainActivityModule::class, AppModule::class])
@Component(modules = [AndroidSupportInjectionModule::class, MainActivityModule::class, AppModule::class])
interface AppComponent {

fun inject(basicApp: BasicApp)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ class DelayObject<F, E : Runnable>(val flag: F, val data: E? = null) : Delayed {
return unit.convert(diff, TimeUnit.MILLISECONDS)
}

override fun compareTo(o: Delayed): Int {
return saturatedCast(this.startTimeMillis - (o as DelayObject<*, *>).startTimeMillis)
override fun compareTo(other: Delayed): Int {
return saturatedCast(this.startTimeMillis - (other as DelayObject<*, *>).startTimeMillis)
}

override fun equals(other: Any?): Boolean {
Expand Down
1 change: 0 additions & 1 deletion lintrules/.gitignore

This file was deleted.

23 changes: 0 additions & 23 deletions lintrules/build.gradle

This file was deleted.

42 changes: 0 additions & 42 deletions lintrules/src/main/java/com/bzh/dytt/lint/LogDetector.java

This file was deleted.

19 changes: 0 additions & 19 deletions lintrules/src/main/java/com/bzh/dytt/lint/MyIssueRegistry.java

This file was deleted.

0 comments on commit 2c14c45

Please sign in to comment.