Utilize CallStyle for incoming and ongoing calls.

This commit is contained in:
Alex Hart
2023-04-18 16:26:04 -03:00
committed by Cody Henthorne
parent 8260be4bff
commit 560b2f7d6f
3 changed files with 42 additions and 44 deletions

View File

@@ -9,7 +9,6 @@ import android.os.ResultReceiver;
import androidx.annotation.AnyThread;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.annotation.RequiresApi;
import com.annimon.stream.Stream;
@@ -61,6 +60,7 @@ import org.thoughtcrime.securesms.util.RecipientAccessList;
import org.thoughtcrime.securesms.util.TextSecurePreferences;
import org.thoughtcrime.securesms.util.Util;
import org.thoughtcrime.securesms.util.rx.RxStore;
import org.thoughtcrime.securesms.webrtc.CallNotificationBuilder;
import org.thoughtcrime.securesms.webrtc.audio.SignalAudioManager;
import org.thoughtcrime.securesms.webrtc.locks.LockManager;
import org.webrtc.PeerConnection;
@@ -413,7 +413,7 @@ private void processStateless(@NonNull Function1<WebRtcEphemeralState, WebRtcEph
}
public boolean startCallCardActivityIfPossible() {
if (Build.VERSION.SDK_INT >= 29 && !ApplicationDependencies.getAppForegroundObserver().isForegrounded()) {
if (Build.VERSION.SDK_INT >= CallNotificationBuilder.API_LEVEL_CALL_STYLE) {
return false;
}