Small lint fixes

This commit is contained in:
Lucas Lima 2020-06-28 12:33:29 -03:00
parent ec3330af19
commit 264c1b217f
No known key found for this signature in database
GPG key ID: 0259A3F43EC1027A
4 changed files with 2 additions and 21 deletions

View file

@ -11,7 +11,7 @@ class TextViewModel(
val text = MutableLiveData<String>()
suspend fun loadText(@RawRes rawFile: Int) {
fun loadText(@RawRes rawFile: Int) {
val result = getApplication<Application>().resources.openRawResource(rawFile)
.bufferedReader()
.readLines()

View file

@ -1,7 +0,0 @@
package dev.lucasnlm.antimine.core.scope
import javax.inject.Scope
@Scope
@Retention(AnnotationRetention.RUNTIME)
annotation class ActivityScope

View file

@ -1,12 +0,0 @@
package dev.lucasnlm.antimine.core.utils
import android.content.Context
import android.content.res.Configuration.UI_MODE_NIGHT_YES
import android.content.res.Configuration.UI_MODE_NIGHT_MASK
fun isDarkModeEnabled(context: Context): Boolean {
return when (context.resources.configuration.uiMode and UI_MODE_NIGHT_MASK) {
UI_MODE_NIGHT_YES -> true
else -> false
}
}

View file

@ -3,7 +3,7 @@ package dev.lucasnlm.antimine.common.level.mocks
import dev.lucasnlm.antimine.common.level.repository.IDimensionRepository
import dev.lucasnlm.antimine.common.level.repository.Size
class FixedDimensionRepository() : IDimensionRepository {
class FixedDimensionRepository : IDimensionRepository {
override fun areaSize(): Float = 50.0f
override fun areaSizeWithPadding(): Float {