Skip to content

Commit b8363cb

Browse files
committed
4.1.0-videochat-kotlin
1 parent 7d09ead commit b8363cb

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+990
-1657
lines changed

sample-videochat-kotlin/app/build.gradle

+14-14
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ buildscript {
44
mavenCentral()
55
}
66
dependencies {
7-
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinGradlePluginVersion"
7+
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.5.31"
88
}
99
}
1010

@@ -29,26 +29,26 @@ android {
2929

3030
compileSdkVersion 31
3131
buildToolsVersion "31.0.0"
32-
flavorDimensions dimensionDefault
32+
flavorDimensions "default"
3333

3434
defaultConfig {
3535
applicationId "com.quickblox.sample.videochat.kotlin"
3636
minSdkVersion 21
3737
targetSdkVersion 31
38-
versionCode 405000
39-
versionName '4.0.5'
38+
versionCode 410000
39+
versionName '4.1.0'
4040
multiDexEnabled true
4141
}
4242

4343
productFlavors {
4444
dev {
45-
dimension dimensionDefault
45+
dimension "default"
4646
buildConfigField('boolean', "IS_QA", "false")
4747
buildConfigField("int", "VERSION_QA_CODE", versionQACode.toString())
4848
}
4949

5050
qa {
51-
dimension dimensionDefault
51+
dimension "default"
5252
buildConfigField("boolean", "IS_QA", "true")
5353
buildConfigField("int", "VERSION_QA_CODE", versionQACode.toString())
5454
}
@@ -92,14 +92,14 @@ android {
9292
}
9393

9494
dependencies {
95-
implementation "com.quickblox:quickblox-android-sdk-videochat-webrtc:$qbSdkVersion"
96-
implementation "com.quickblox:quickblox-android-sdk-messages:$qbSdkVersion"
97-
implementation "com.google.firebase:firebase-core:$firebaseCoreVersion"
98-
implementation "com.google.android.material:material:$materialVersion"
99-
implementation "com.github.johnkil.android-robototextview:robototextview:$robotoTextViewVersion"
100-
implementation "androidx.fragment:fragment-ktx:$fragmentAndroidXVersion"
101-
implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycleViewmodelAndroidXVersion"
102-
implementation "androidx.core:core-ktx:$coreKtxVersion"
95+
implementation 'com.quickblox:quickblox-android-sdk-videochat-webrtc:3.10.1'
96+
implementation 'com.quickblox:quickblox-android-sdk-messages:3.10.1'
97+
implementation 'com.google.firebase:firebase-core:21.1.0'
98+
implementation 'com.google.android.material:material:1.6.1'
99+
implementation 'com.github.johnkil.android-robototextview:robototextview:4.0.0'
100+
implementation 'androidx.fragment:fragment-ktx:1.5.2'
101+
implementation 'androidx.lifecycle:lifecycle-viewmodel-ktx:2.5.1'
102+
implementation 'androidx.core:core-ktx:1.8.0'
103103
}
104104

105105
apply from: "../artifacts.gradle"

sample-videochat-kotlin/app/proguard-rules.pro

+4-1
Original file line numberDiff line numberDiff line change
@@ -41,4 +41,7 @@
4141
-keep class org.webrtc.** { *; }
4242

4343
#google gms
44-
-keep class com.google.android.gms.** { *; }
44+
-keep class com.google.android.gms.** { *; }
45+
46+
#json
47+
-keep class org.json.** { *; }

sample-videochat-kotlin/app/src/main/AndroidManifest.xml

-5
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,6 @@
3737
android:name=".activities.LoginActivity"
3838
android:screenOrientation="portrait" />
3939

40-
<activity
41-
android:name=".activities.SettingsActivity"
42-
android:configChanges="keyboardHidden|screenSize|orientation"
43-
android:screenOrientation="portrait" />
44-
4540
<activity
4641
android:name=".activities.OpponentsActivity"
4742
android:screenOrientation="portrait" />

sample-videochat-kotlin/app/src/main/java/com/quickblox/sample/videochat/kotlin/App.kt

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ import android.app.Application
44
import com.quickblox.auth.session.QBSettings
55
import com.quickblox.sample.videochat.kotlin.db.DbHelper
66

7-
//User default credentials
7+
// user default credentials
88
const val DEFAULT_USER_PASSWORD = "quickblox"
99

10-
//App credentials
10+
// app credentials
1111
private const val APPLICATION_ID = ""
1212
private const val AUTH_KEY = ""
1313
private const val AUTH_SECRET = ""
@@ -42,7 +42,7 @@ class App : Application() {
4242
QBSettings.getInstance().init(applicationContext, APPLICATION_ID, AUTH_KEY, AUTH_SECRET)
4343
QBSettings.getInstance().accountKey = ACCOUNT_KEY
4444

45-
// Uncomment and put your Api and Chat servers endpoints if you want to point the sample
45+
// uncomment and put your Api and Chat servers endpoints if you want to point the sample
4646
// against your own server.
4747
//
4848
// QBSettings.getInstance().setEndpoints("https://your_api_endpoint.com", "your_chat_endpoint", ServiceZone.PRODUCTION);

sample-videochat-kotlin/app/src/main/java/com/quickblox/sample/videochat/kotlin/activities/AppInfoActivity.kt

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ class AppInfoActivity : AppCompatActivity() {
7171
appQAVersionTextView.setText(spannable, TextView.BufferType.SPANNABLE)
7272
appQAVersionTextView.visibility = View.VISIBLE
7373

74-
findViewById<View>(R.id.text_qa_version_title).visibility = View.VISIBLE
74+
findViewById<TextView>(R.id.text_qa_version_title).visibility = View.VISIBLE
7575
}
7676
}
7777

sample-videochat-kotlin/app/src/main/java/com/quickblox/sample/videochat/kotlin/activities/BaseActivity.kt

+10-16
Original file line numberDiff line numberDiff line change
@@ -11,23 +11,19 @@ import androidx.core.content.ContextCompat
1111
import com.quickblox.sample.videochat.kotlin.R
1212
import com.quickblox.sample.videochat.kotlin.utils.showErrorSnackbar
1313

14-
1514
abstract class BaseActivity : AppCompatActivity() {
1615
private var progressDialog: ProgressDialog? = null
1716

18-
1917
internal fun showProgressDialog(@StringRes messageId: Int) {
2018
if (progressDialog == null) {
2119
progressDialog = ProgressDialog(this)
22-
progressDialog!!.isIndeterminate = true
23-
progressDialog!!.setCancelable(false)
24-
progressDialog!!.setCanceledOnTouchOutside(false)
25-
26-
// Disable the back button
27-
progressDialog!!.setOnKeyListener(KeyEventListener())
20+
progressDialog?.isIndeterminate = true
21+
progressDialog?.setCancelable(false)
22+
progressDialog?.setCanceledOnTouchOutside(false)
23+
progressDialog?.setOnKeyListener(KeyEventListener())
2824
}
29-
progressDialog!!.setMessage(getString(messageId))
30-
progressDialog!!.show()
25+
progressDialog?.setMessage(getString(messageId))
26+
progressDialog?.show()
3127
}
3228

3329
override fun onPause() {
@@ -36,16 +32,14 @@ abstract class BaseActivity : AppCompatActivity() {
3632
}
3733

3834
internal fun hideProgressDialog() {
39-
if (progressDialog != null && progressDialog?.isShowing == true) {
40-
progressDialog!!.dismiss()
35+
if (progressDialog?.isShowing == true) {
36+
progressDialog?.dismiss()
4137
}
4238
}
4339

44-
protected fun showErrorSnackbar(@StringRes resId: Int, e: Exception, clickListener: View.OnClickListener) {
40+
protected fun showErrorSnackbar(@StringRes resId: Int, e: Exception?, clickListener: View.OnClickListener) {
4541
val rootView = window.decorView.findViewById<View>(android.R.id.content)
46-
if (rootView != null) {
47-
showErrorSnackbar(rootView, resId, e, R.string.dlg_retry, clickListener)
48-
}
42+
showErrorSnackbar(rootView, resId, e, R.string.dlg_retry, clickListener)
4943
}
5044

5145
protected fun checkPermissions(permissions: Array<String>): Boolean {

0 commit comments

Comments
 (0)