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

Commit ffdb144c authored by Matt Sziklay's avatar Matt Sziklay Committed by Android (Google) Code Review
Browse files

Merge "Log UIEvent metrics for Multi Instance features." into main

parents 7c0d543e 23ba6b73
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -145,7 +145,11 @@ class DesktopModeUiEventLogger(
        @UiEvent(doc = "Moving the desktop window by dragging the header")
        DESKTOP_WINDOW_MOVE_BY_HEADER_DRAG(2021),
        @UiEvent(doc = "Double tap on the window header to refocus a desktop window")
        DESKTOP_WINDOW_HEADER_TAP_TO_REFOCUS(2022);
        DESKTOP_WINDOW_HEADER_TAP_TO_REFOCUS(2022),
        @UiEvent(doc = "Enter multi-instance by using the New Window button")
        DESKTOP_WINDOW_MULTI_INSTANCE_NEW_WINDOW_CLICK(2069),
        @UiEvent(doc = "Enter multi-instance by clicking an icon in the Manage Windows menu")
        DESKTOP_WINDOW_MULTI_INSTANCE_MANAGE_WINDOWS_ICON_CLICK(2070);

        override fun getId(): Int = mId
    }
+5 −0
Original line number Diff line number Diff line
@@ -795,6 +795,8 @@ public class DesktopModeWindowDecorViewModel implements WindowDecorViewModel,
        }
        decoration.closeHandleMenu();
        mDesktopTasksController.openNewWindow(decoration.mTaskInfo);
        mDesktopModeUiEventLogger.log(decoration.mTaskInfo,
                DesktopUiEventEnum.DESKTOP_WINDOW_MULTI_INSTANCE_NEW_WINDOW_CLICK);
    }

    private void onManageWindows(DesktopModeWindowDecoration decoration) {
@@ -811,6 +813,9 @@ public class DesktopModeWindowDecorViewModel implements WindowDecorViewModel,
                        decoration.closeManageWindowsMenu();
                        mDesktopTasksController.openInstance(decoration.mTaskInfo,
                                requestedTaskId);
                        mDesktopModeUiEventLogger.log(decoration.mTaskInfo,
                                DesktopUiEventEnum
                                        .DESKTOP_WINDOW_MULTI_INSTANCE_MANAGE_WINDOWS_ICON_CLICK);
                        return Unit.INSTANCE;
                    }
                )