Skip to content

Commit 2d23e1b

Browse files
Updated Phone Call Detection Kotlin to latest Android API, SDK and gradle config
1 parent afe9a88 commit 2d23e1b

File tree

6 files changed

+26
-35
lines changed

6 files changed

+26
-35
lines changed

Phone-Call-Detection-Kotlin/app/build.gradle

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ apply {
99

1010
android {
1111
compileSdkVersion extCompileSdkVersion
12-
buildToolsVersion extBuildToolsVersion
1312

1413
defaultConfig {
1514
applicationId "com.tokbox.sample.phonecalldetection"
@@ -43,5 +42,5 @@ dependencies {
4342
implementation "pub.devrel:easypermissions:${extEasyPermissionsVersion}"
4443
implementation "androidx.constraintlayout:constraintlayout:${extConstraintLyoutVersion}"
4544
implementation "androidx.core:core-ktx:+"
46-
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
45+
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.6.10"
4746
}

Phone-Call-Detection-Kotlin/app/src/main/AndroidManifest.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<activity
2020
android:name="com.tokbox.sample.phonecalldetection.MainActivity"
2121
android:screenOrientation="portrait"
22-
android:label="@string/app_name" >
22+
android:exported="true">
2323
<intent-filter>
2424
<action android:name="android.intent.action.MAIN" />
2525

Lines changed: 7 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,10 @@
11
// Top-level build file where you can add configuration options common to all sub-projects/modules.
2-
3-
buildscript {
4-
ext.kotlin_version = "1.5.20"
5-
6-
apply {
7-
from '../commons.gradle'
8-
}
9-
10-
repositories {
11-
google()
12-
mavenCentral()
13-
}
14-
dependencies {
15-
// Dependency versions are defined in the ../commons.gradle file
16-
classpath "com.android.tools.build:gradle:${extAgpVersion}"
17-
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
18-
19-
// NOTE: Do not place your application dependencies here; they belong
20-
// in the individual module build.gradle files
21-
}
2+
plugins {
3+
id 'com.android.application' version '7.1.2' apply false
4+
id 'com.android.library' version '7.1.2' apply false
5+
id 'org.jetbrains.kotlin.android' version '1.6.10' apply false
226
}
237

24-
allprojects {
25-
repositories {
26-
google()
27-
mavenCentral()
28-
}
29-
}
30-
31-
repositories {
32-
mavenCentral()
33-
}
8+
task clean(type: Delete) {
9+
delete rootProject.buildDir
10+
}

Phone-Call-Detection-Kotlin/gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
# Specifies the JVM arguments used for the daemon process.
1111
# The setting is particularly useful for tweaking memory settings.
12-
org.gradle.jvmargs=-Xmx2048m
12+
org.gradle.jvmargs=-Xmx4096m
1313

1414
# When configured, Gradle will run in incubating parallel mode.
1515
# This option should only be used with decoupled projects. More details, visit

Phone-Call-Detection-Kotlin/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists
6-
distributionUrl=https\://services.gradle.org/distributions/gradle-6.9-bin.zip
6+
distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-bin.zip
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,16 @@
1+
pluginManagement {
2+
repositories {
3+
gradlePluginPortal()
4+
google()
5+
mavenCentral()
6+
}
7+
}
8+
dependencyResolutionManagement {
9+
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
10+
repositories {
11+
google()
12+
mavenCentral()
13+
}
14+
}
15+
116
include ':app'

0 commit comments

Comments
 (0)