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

Commit 14d92a09 authored by Matt Casey's avatar Matt Casey
Browse files

Fall back to default display if focused is unavailable.

Matching screenshot behavior.

Bug: 442094382
Flag: EXEMPT bugfix
Test: manually forced null value
Change-Id: Idf9cff9ce22444f3e1f9f87e040dd45c8788d44f
parent 8d900756
Loading
Loading
Loading
Loading
+3 −0
Original line number Original line Diff line number Diff line
@@ -60,6 +60,9 @@ public interface ClipboardOverlayModule {
            UserTracker userTracker, FocusedDisplayRepository focusedDisplayRepository) {
            UserTracker userTracker, FocusedDisplayRepository focusedDisplayRepository) {
        Display display = displayManager.getDisplay(
        Display display = displayManager.getDisplay(
                focusedDisplayRepository.getFocusedDisplayId().getValue());
                focusedDisplayRepository.getFocusedDisplayId().getValue());
        if (display == null) {
            display = displayManager.getDisplay(Display.DEFAULT_DISPLAY);
        }
        if (clipboardOverlayMultiuser()) {
        if (clipboardOverlayMultiuser()) {
            return userTracker.getUserContext().createWindowContext(display, TYPE_SCREENSHOT, null);
            return userTracker.getUserContext().createWindowContext(display, TYPE_SCREENSHOT, null);
        } else {
        } else {