mirror of
https://github.com/signalapp/Signal-Android.git
synced 2025-12-23 04:28:35 +00:00
Prevent controls from appearing when a call glare occurs.
This commit is contained in:
@@ -284,7 +284,7 @@ class ControlsAndInfoController private constructor(
|
|||||||
|
|
||||||
private fun hide(delay: Long = 0L) {
|
private fun hide(delay: Long = 0L) {
|
||||||
if (delay == 0L) {
|
if (delay == 0L) {
|
||||||
if (controlState.isFadeOutEnabled || controlState == WebRtcControls.PIP || controlState.displayErrorControls()) {
|
if (controlState.isFadeOutEnabled || controlState == WebRtcControls.PIP || controlState.displayErrorControls() || controlState.displayIncomingCallButtons()) {
|
||||||
behavior.isHideable = true
|
behavior.isHideable = true
|
||||||
behavior.state = BottomSheetBehavior.STATE_HIDDEN
|
behavior.state = BottomSheetBehavior.STATE_HIDDEN
|
||||||
|
|
||||||
@@ -343,7 +343,7 @@ class ControlsAndInfoController private constructor(
|
|||||||
}
|
}
|
||||||
|
|
||||||
private fun showOrHideControlsOnUpdate(previousState: WebRtcControls) {
|
private fun showOrHideControlsOnUpdate(previousState: WebRtcControls) {
|
||||||
if (controlState == WebRtcControls.PIP || controlState.displayErrorControls()) {
|
if (controlState == WebRtcControls.PIP || controlState.displayErrorControls() || controlState.displayIncomingCallButtons()) {
|
||||||
hide()
|
hide()
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user