diff --git a/vector-app/src/debug/AndroidManifest.xml b/vector-app/src/debug/AndroidManifest.xml index a7867f4081..be2aadbeaf 100644 --- a/vector-app/src/debug/AndroidManifest.xml +++ b/vector-app/src/debug/AndroidManifest.xml @@ -4,6 +4,7 @@ + diff --git a/vector-app/src/debug/java/im/vector/app/features/debug/DebugMenuActivity.kt b/vector-app/src/debug/java/im/vector/app/features/debug/DebugMenuActivity.kt index f431192efd..92c7ebffdc 100644 --- a/vector-app/src/debug/java/im/vector/app/features/debug/DebugMenuActivity.kt +++ b/vector-app/src/debug/java/im/vector/app/features/debug/DebugMenuActivity.kt @@ -35,6 +35,7 @@ import im.vector.app.core.utils.registerForPermissionsResult import im.vector.app.core.utils.toast import im.vector.app.features.debug.analytics.DebugAnalyticsActivity import im.vector.app.features.debug.features.DebugFeaturesSettingsActivity +import im.vector.app.features.debug.jitsi.DebugJitsiActivity import im.vector.app.features.debug.leak.DebugMemoryLeaksActivity import im.vector.app.features.debug.sas.DebugSasEmojiActivity import im.vector.app.features.debug.settings.DebugPrivateSettingsActivity @@ -121,6 +122,9 @@ class DebugMenuActivity : VectorBaseActivity() { views.debugPermission.setOnClickListener { startActivity(Intent(this, DebugPermissionActivity::class.java)) } + views.debugJitsi.setOnClickListener { + startActivity(Intent(this, DebugJitsiActivity::class.java)) + } } private fun openPrivateSettings() { diff --git a/vector-app/src/debug/java/im/vector/app/features/debug/jitsi/DebugJitsiActivity.kt b/vector-app/src/debug/java/im/vector/app/features/debug/jitsi/DebugJitsiActivity.kt new file mode 100644 index 0000000000..5c6c5d1898 --- /dev/null +++ b/vector-app/src/debug/java/im/vector/app/features/debug/jitsi/DebugJitsiActivity.kt @@ -0,0 +1,45 @@ +/* + * Copyright (c) 2022 New Vector Ltd + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package im.vector.app.features.debug.jitsi + +import android.annotation.SuppressLint +import dagger.hilt.android.AndroidEntryPoint +import im.vector.app.core.platform.VectorBaseActivity +import im.vector.application.databinding.ActivityDebugJitsiBinding +import org.jitsi.meet.sdk.JitsiMeet + +@AndroidEntryPoint +class DebugJitsiActivity : VectorBaseActivity() { + + override fun getBinding() = ActivityDebugJitsiBinding.inflate(layoutInflater) + + override fun getCoordinatorLayout() = views.coordinatorLayout + + @SuppressLint("SetTextI18n") + override fun initUiAndData() { + val isCrashReportingDisabled = JitsiMeet.isCrashReportingDisabled(this) + views.status.text = "Jitsi crash reporting is disabled: $isCrashReportingDisabled" + + views.splash.setOnClickListener { + JitsiMeet.showSplashScreen(this) + } + + views.dev.setOnClickListener { + JitsiMeet.showDevOptions() + } + } +} diff --git a/vector-app/src/debug/res/layout/activity_debug_jitsi.xml b/vector-app/src/debug/res/layout/activity_debug_jitsi.xml new file mode 100644 index 0000000000..0a13594854 --- /dev/null +++ b/vector-app/src/debug/res/layout/activity_debug_jitsi.xml @@ -0,0 +1,47 @@ + + + + + + + + + +