diff --git a/vector/src/main/java/im/vector/app/features/call/VectorCallActivity.kt b/vector/src/main/java/im/vector/app/features/call/VectorCallActivity.kt index 7862c1beb4..56494bbf4b 100644 --- a/vector/src/main/java/im/vector/app/features/call/VectorCallActivity.kt +++ b/vector/src/main/java/im/vector/app/features/call/VectorCallActivity.kt @@ -232,7 +232,6 @@ class VectorCallActivity : VectorBaseActivity(), CallContro private fun renderFullScreenMode(state: VectorCallViewState) { views.callToolbar.isVisible = true views.callControlsView.isVisible = true - views.pipRendererWrapper.isVisible = true views.callControlsView.updateForState(state) val callState = state.callState.invoke() views.callActionText.setOnClickListener(null) @@ -243,13 +242,13 @@ class VectorCallActivity : VectorBaseActivity(), CallContro is CallState.CreateOffer, is CallState.LocalRinging, is CallState.Dialing -> { - views.callVideoGroup.isInvisible = true + views.callVideoGroup.isVisible = false views.callInfoGroup.isVisible = true views.callToolbar.setSubtitle(R.string.call_ringing) configureCallInfo(state) } is CallState.Answering -> { - views.callVideoGroup.isInvisible = true + views.callVideoGroup.isVisible = false views.callInfoGroup.isVisible = true views.callToolbar.setSubtitle(R.string.call_connecting) configureCallInfo(state) @@ -259,7 +258,7 @@ class VectorCallActivity : VectorBaseActivity(), CallContro if (callState.iceConnectionState == MxPeerConnectionState.CONNECTED) { if (state.isLocalOnHold || state.isRemoteOnHold) { views.smallIsHeldIcon.isVisible = true - views.callVideoGroup.isInvisible = true + views.callVideoGroup.isVisible = false views.callInfoGroup.isVisible = true configureCallInfo(state, blurAvatar = true) if (state.isRemoteOnHold) { @@ -290,13 +289,13 @@ class VectorCallActivity : VectorBaseActivity(), CallContro views.callInfoGroup.isVisible = false views.pipRenderer.isVisible = !state.isVideoCaptureInError && state.otherKnownCallInfo == null } else { - views.callVideoGroup.isInvisible = true + views.callVideoGroup.isVisible = false views.callInfoGroup.isVisible = true } } } else { // This state is not final, if you change network, new candidates will be sent - views.callVideoGroup.isInvisible = true + views.callVideoGroup.isVisible = false views.callInfoGroup.isVisible = true configureCallInfo(state) views.callToolbar.setSubtitle(R.string.call_connecting) diff --git a/vector/src/main/res/layout/activity_call.xml b/vector/src/main/res/layout/activity_call.xml index 0a6c89426f..e611851a38 100644 --- a/vector/src/main/res/layout/activity_call.xml +++ b/vector/src/main/res/layout/activity_call.xml @@ -36,6 +36,7 @@ app:cardCornerRadius="@dimen/call_pip_radius" android:layout_marginBottom="16dp" android:layout_marginEnd="16dp" + app:layout_goneMarginEnd="0dp" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintBottom_toTopOf="@id/callControlsView"> @@ -71,16 +72,16 @@ android:id="@+id/otherKnownCallLayout" android:layout_width="@dimen/call_pip_width" android:layout_height="@dimen/call_pip_height" - android:layout_marginTop="32dp" android:layout_marginEnd="16dp" + android:layout_marginBottom="16dp" android:background="@color/element_background_light" android:foreground="?attr/selectableItemBackground" android:visibility="gone" app:cardBackgroundColor="@color/bg_call_screen" app:cardCornerRadius="@dimen/call_pip_radius" app:cardElevation="4dp" - app:layout_constraintEnd_toEndOf="parent" - app:layout_constraintTop_toTopOf="parent" + app:layout_constraintBottom_toTopOf="@id/callControlsView" + app:layout_constraintEnd_toStartOf="@id/pipRendererWrapper" tools:visibility="visible">