Skip to content

Commit c5e8e39

Browse files
committed
Downgrade minVersionApi to 14
1 parent fa15749 commit c5e8e39

File tree

3 files changed

+8
-3
lines changed

3 files changed

+8
-3
lines changed

app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ android {
88
compileSdkVersion 28
99
defaultConfig {
1010
applicationId "com.omegar.simple.omegalaunchers"
11-
minSdkVersion 16
11+
minSdkVersion 14
1212
targetSdkVersion 28
1313
versionCode 1
1414
versionName "1.0"

omegalauncherslib/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ android {
77

88

99
defaultConfig {
10-
minSdkVersion 16
10+
minSdkVersion 14
1111
targetSdkVersion 28
1212
versionCode 1
1313
versionName "1.0"

omegalauncherslib/src/main/java/com/omegar/libs/omegalaunchers/ActivityLauncher.kt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import android.app.Activity
44
import android.app.PendingIntent
55
import android.content.Context
66
import android.content.Intent
7+
import android.os.Build
78
import android.os.Bundle
89
import android.os.Parcelable
910
import android.util.AndroidRuntimeException
@@ -86,7 +87,11 @@ class ActivityLauncher(
8687
}
8788

8889
private fun Activity.compatStartActivityForResult(intent: Intent, requestCode: Int, option: Bundle? = null) {
89-
startActivityForResult(intent, requestCode, option)
90+
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN) {
91+
startActivityForResult(intent, requestCode, option)
92+
} else {
93+
startActivityForResult(intent, requestCode)
94+
}
9095
}
9196

9297
fun getPendingIntent(

0 commit comments

Comments
 (0)