From 0c95794463ee21317725f6934dc55bd8dc83e0c0 Mon Sep 17 00:00:00 2001 From: Romain Vimont Date: Sat, 10 Aug 2024 14:27:22 +0200 Subject: [PATCH] Do not apply all workarounds for ONYX devices Calling fillAppInfo() breaks video mirroring on ONYX devices. Fixes #5182 Refs 2b6089cbfc29c41643e0c0e8049bda3ede777b61 --- .../src/main/java/com/genymobile/scrcpy/Workarounds.java | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/server/src/main/java/com/genymobile/scrcpy/Workarounds.java b/server/src/main/java/com/genymobile/scrcpy/Workarounds.java index 8fc38555..7de98b72 100644 --- a/server/src/main/java/com/genymobile/scrcpy/Workarounds.java +++ b/server/src/main/java/com/genymobile/scrcpy/Workarounds.java @@ -61,7 +61,14 @@ public final class Workarounds { fillConfigurationController(); } - fillAppInfo(); + // On ONYX devices, fillAppInfo() breaks video mirroring: + // + boolean mustFillAppInfo = !Build.BRAND.equalsIgnoreCase("ONYX"); + + if (mustFillAppInfo) { + fillAppInfo(); + } + fillAppContext(); }