Add a DebugJitsiActivity for debug build only. It's quite useless...
This commit is contained in:
parent
4515dcdfe9
commit
16a5046601
@ -4,6 +4,7 @@
|
|||||||
<application>
|
<application>
|
||||||
<activity android:name="im.vector.app.features.debug.TestLinkifyActivity" />
|
<activity android:name="im.vector.app.features.debug.TestLinkifyActivity" />
|
||||||
<activity android:name="im.vector.app.features.debug.DebugPermissionActivity" />
|
<activity android:name="im.vector.app.features.debug.DebugPermissionActivity" />
|
||||||
|
<activity android:name="im.vector.app.features.debug.jitsi.DebugJitsiActivity" />
|
||||||
<activity android:name="im.vector.app.features.debug.analytics.DebugAnalyticsActivity" />
|
<activity android:name="im.vector.app.features.debug.analytics.DebugAnalyticsActivity" />
|
||||||
<activity android:name="im.vector.app.features.debug.settings.DebugPrivateSettingsActivity" />
|
<activity android:name="im.vector.app.features.debug.settings.DebugPrivateSettingsActivity" />
|
||||||
<activity android:name="im.vector.app.features.debug.sas.DebugSasEmojiActivity" />
|
<activity android:name="im.vector.app.features.debug.sas.DebugSasEmojiActivity" />
|
||||||
|
@ -35,6 +35,7 @@ import im.vector.app.core.utils.registerForPermissionsResult
|
|||||||
import im.vector.app.core.utils.toast
|
import im.vector.app.core.utils.toast
|
||||||
import im.vector.app.features.debug.analytics.DebugAnalyticsActivity
|
import im.vector.app.features.debug.analytics.DebugAnalyticsActivity
|
||||||
import im.vector.app.features.debug.features.DebugFeaturesSettingsActivity
|
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.leak.DebugMemoryLeaksActivity
|
||||||
import im.vector.app.features.debug.sas.DebugSasEmojiActivity
|
import im.vector.app.features.debug.sas.DebugSasEmojiActivity
|
||||||
import im.vector.app.features.debug.settings.DebugPrivateSettingsActivity
|
import im.vector.app.features.debug.settings.DebugPrivateSettingsActivity
|
||||||
@ -121,6 +122,9 @@ class DebugMenuActivity : VectorBaseActivity<ActivityDebugMenuBinding>() {
|
|||||||
views.debugPermission.setOnClickListener {
|
views.debugPermission.setOnClickListener {
|
||||||
startActivity(Intent(this, DebugPermissionActivity::class.java))
|
startActivity(Intent(this, DebugPermissionActivity::class.java))
|
||||||
}
|
}
|
||||||
|
views.debugJitsi.setOnClickListener {
|
||||||
|
startActivity(Intent(this, DebugJitsiActivity::class.java))
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun openPrivateSettings() {
|
private fun openPrivateSettings() {
|
||||||
|
@ -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<ActivityDebugJitsiBinding>() {
|
||||||
|
|
||||||
|
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()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
47
vector-app/src/debug/res/layout/activity_debug_jitsi.xml
Normal file
47
vector-app/src/debug/res/layout/activity_debug_jitsi.xml
Normal file
@ -0,0 +1,47 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<androidx.coordinatorlayout.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:id="@+id/coordinatorLayout"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="match_parent"
|
||||||
|
tools:context="im.vector.app.features.debug.jitsi.DebugJitsiActivity"
|
||||||
|
tools:ignore="HardcodedText">
|
||||||
|
|
||||||
|
<ScrollView
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:divider="@drawable/linear_divider"
|
||||||
|
android:gravity="center_horizontal"
|
||||||
|
android:orientation="vertical"
|
||||||
|
android:padding="@dimen/layout_horizontal_margin"
|
||||||
|
android:showDividers="middle">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/status"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
tools:text="Status" />
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/splash"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="Splash"
|
||||||
|
android:textAllCaps="false" />
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/dev"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="Dev options"
|
||||||
|
android:textAllCaps="false" />
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
</ScrollView>
|
||||||
|
|
||||||
|
</androidx.coordinatorlayout.widget.CoordinatorLayout>
|
@ -186,6 +186,12 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="Permissions" />
|
android:text="Permissions" />
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/debug_jitsi"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:text="Jitsi" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
</ScrollView>
|
</ScrollView>
|
||||||
|
Loading…
Reference in New Issue
Block a user