Skip to content

Commit 869fb11

Browse files
committed
updating commons, set minimal Android version to 6
1 parent dcb34c2 commit 869fb11

File tree

5 files changed

+5
-49
lines changed

5 files changed

+5
-49
lines changed

app/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ android {
1313

1414
defaultConfig {
1515
applicationId "com.simplemobiletools.flashlight"
16-
minSdkVersion 21
16+
minSdkVersion 23
1717
targetSdkVersion 33
1818
versionCode 61
1919
versionName "5.8.4"
@@ -62,7 +62,7 @@ android {
6262
}
6363

6464
dependencies {
65-
implementation 'com.github.SimpleMobileTools:Simple-Commons:f538687d6e'
65+
implementation 'com.github.SimpleMobileTools:Simple-Commons:31cb0b37cf'
6666
implementation 'org.greenrobot:eventbus:3.3.1'
6767
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
6868
}

app/src/main/kotlin/com/simplemobiletools/flashlight/helpers/LollipopCameraFlash.kt

Lines changed: 0 additions & 42 deletions
This file was deleted.

app/src/main/kotlin/com/simplemobiletools/flashlight/helpers/MarshmallowPlusCameraFlash.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import com.simplemobiletools.flashlight.extensions.config
1212
import com.simplemobiletools.flashlight.models.Events
1313
import org.greenrobot.eventbus.EventBus
1414

15-
@RequiresApi(Build.VERSION_CODES.M)
1615
internal class MarshmallowPlusCameraFlash(
1716
private val context: Context,
1817
private var cameraTorchListener: CameraTorchListener? = null,

app/src/main/kotlin/com/simplemobiletools/flashlight/helpers/MyCameraImpl.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import android.content.Context
44
import android.os.Handler
55
import com.simplemobiletools.commons.extensions.showErrorToast
66
import com.simplemobiletools.commons.extensions.toast
7-
import com.simplemobiletools.commons.helpers.isMarshmallowPlus
87
import com.simplemobiletools.flashlight.R
98
import com.simplemobiletools.flashlight.extensions.config
109
import com.simplemobiletools.flashlight.extensions.updateWidgets
@@ -133,7 +132,7 @@ class MyCameraImpl private constructor(val context: Context, private var cameraT
133132
fun handleCameraSetup() {
134133
try {
135134
if (cameraFlash == null) {
136-
cameraFlash = if (isMarshmallowPlus()) MarshmallowPlusCameraFlash(context, cameraTorchListener) else LollipopCameraFlash()
135+
cameraFlash = MarshmallowPlusCameraFlash(context, cameraTorchListener)
137136
}
138137
} catch (e: Exception) {
139138
EventBus.getDefault().post(Events.CameraUnavailable())

app/src/main/res/menu/menu.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
xmlns:app="http://schemas.android.com/apk/res-auto">
44
<item
55
android:id="@+id/more_apps_from_us"
6-
android:showAsAction="never"
6+
android:icon="@drawable/ic_google_play_vector"
77
android:title="@string/more_apps_from_us"
8-
app:showAsAction="never" />
8+
app:showAsAction="always" />
99
<item
1010
android:id="@+id/settings"
1111
android:icon="@drawable/ic_settings_cog_vector"

0 commit comments

Comments
 (0)