update commons to 3.0.12
This commit is contained in:
parent
b5e0761d8c
commit
9aa7935590
|
@ -46,7 +46,7 @@ ext {
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
implementation 'com.simplemobiletools:commons:3.0.3'
|
implementation 'com.simplemobiletools:commons:3.0.12'
|
||||||
|
|
||||||
debugImplementation "com.squareup.leakcanary:leakcanary-android:$leakCanaryVersion"
|
debugImplementation "com.squareup.leakcanary:leakcanary-android:$leakCanaryVersion"
|
||||||
releaseImplementation "com.squareup.leakcanary:leakcanary-android-no-op:$leakCanaryVersion"
|
releaseImplementation "com.squareup.leakcanary:leakcanary-android-no-op:$leakCanaryVersion"
|
||||||
|
|
|
@ -2,9 +2,8 @@ package com.simplemobiletools.camera
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import com.simplemobiletools.camera.BuildConfig.USE_LEAK_CANARY
|
import com.simplemobiletools.camera.BuildConfig.USE_LEAK_CANARY
|
||||||
import com.simplemobiletools.camera.extensions.config
|
import com.simplemobiletools.commons.extensions.checkUseEnglish
|
||||||
import com.squareup.leakcanary.LeakCanary
|
import com.squareup.leakcanary.LeakCanary
|
||||||
import java.util.*
|
|
||||||
|
|
||||||
class App : Application() {
|
class App : Application() {
|
||||||
override fun onCreate() {
|
override fun onCreate() {
|
||||||
|
@ -16,10 +15,6 @@ class App : Application() {
|
||||||
LeakCanary.install(this)
|
LeakCanary.install(this)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (config.useEnglish) {
|
checkUseEnglish()
|
||||||
val conf = resources.configuration
|
|
||||||
conf.locale = Locale.ENGLISH
|
|
||||||
resources.updateConfiguration(conf, resources.displayMetrics)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -54,6 +54,7 @@ class MainActivity : SimpleActivity(), PreviewListener, PhotoProcessor.MediaSave
|
||||||
override fun onCreate(savedInstanceState: Bundle?) {
|
override fun onCreate(savedInstanceState: Bundle?) {
|
||||||
useDynamicTheme = false
|
useDynamicTheme = false
|
||||||
super.onCreate(savedInstanceState)
|
super.onCreate(savedInstanceState)
|
||||||
|
appLaunched()
|
||||||
requestWindowFeature(Window.FEATURE_NO_TITLE)
|
requestWindowFeature(Window.FEATURE_NO_TITLE)
|
||||||
window.addFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN)
|
window.addFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN)
|
||||||
if (config.alwaysOpenBackCamera)
|
if (config.alwaysOpenBackCamera)
|
||||||
|
@ -62,7 +63,6 @@ class MainActivity : SimpleActivity(), PreviewListener, PhotoProcessor.MediaSave
|
||||||
initVariables()
|
initVariables()
|
||||||
tryInitCamera()
|
tryInitCamera()
|
||||||
supportActionBar?.hide()
|
supportActionBar?.hide()
|
||||||
storeStoragePaths()
|
|
||||||
checkWhatsNewDialog()
|
checkWhatsNewDialog()
|
||||||
setupOrientationEventListener()
|
setupOrientationEventListener()
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,10 +1,5 @@
|
||||||
package com.simplemobiletools.camera.activities
|
package com.simplemobiletools.camera.activities
|
||||||
|
|
||||||
import android.os.Bundle
|
|
||||||
import com.simplemobiletools.commons.activities.BaseSimpleActivity
|
import com.simplemobiletools.commons.activities.BaseSimpleActivity
|
||||||
|
|
||||||
open class SimpleActivity : BaseSimpleActivity() {
|
open class SimpleActivity : BaseSimpleActivity()
|
||||||
override fun onCreate(savedInstanceState: Bundle?) {
|
|
||||||
super.onCreate(savedInstanceState)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ import java.io.File
|
||||||
import java.text.SimpleDateFormat
|
import java.text.SimpleDateFormat
|
||||||
import java.util.*
|
import java.util.*
|
||||||
|
|
||||||
val Context.config: Config get() = Config.newInstance(this)
|
val Context.config: Config get() = Config.newInstance(applicationContext)
|
||||||
|
|
||||||
internal val Context.windowManager: WindowManager get() = getSystemService(Context.WINDOW_SERVICE) as WindowManager
|
internal val Context.windowManager: WindowManager get() = getSystemService(Context.WINDOW_SERVICE) as WindowManager
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue