Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f563b133 authored by Johannes Gallmann's avatar Johannes Gallmann
Browse files

Fix crash due to gesture monitor registered on virtual display

Bug: 415765055
Test: DeviceAssociationTest
Test: Manual, i.e. verified trackpad back gesture on connected display
Flag: com.android.window.flags.enable_multidisplay_trackpad_back_gesture
Change-Id: I8b898c1fc3fe63c23186fe7e5ed535c5b4346815
parent 4ab15dad
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -703,7 +703,11 @@ public class EdgeBackGestureHandler {
                }
                Display display = mDisplayManager.getDisplay(displayId);
                if (display == null) {
                    Log.w(TAG, "createDisplayBackGestureHandler: can't find display");
                    Log.w(TAG, "onDisplayAddSystemDecorations: can't find display");
                    return;
                }
                if (display.getType() != Display.TYPE_EXTERNAL) {
                    Log.w(TAG, "onDisplayAddSystemDecorations: display is not of TYPE_EXTERNAL");
                    return;
                }
                removeAndDisposeDisplayResource(displayId);