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

Commit 2fef2fbc authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Using inteface descriptor as the key for various interface extras" into main

parents 0314dc15 3f08004e
Loading
Loading
Loading
Loading
+0 −23
Original line number Diff line number Diff line
@@ -20,29 +20,6 @@ package com.android.wm.shell.shared;
 * General shell-related constants that are shared with users of the library.
 */
public class ShellSharedConstants {
    // See IPip.aidl
    public static final String KEY_EXTRA_SHELL_PIP = "extra_shell_pip";
    // See IBubbles.aidl
    public static final String KEY_EXTRA_SHELL_BUBBLES = "extra_shell_bubbles";
    // See ISplitScreen.aidl
    public static final String KEY_EXTRA_SHELL_SPLIT_SCREEN = "extra_shell_split_screen";
    // See IOneHanded.aidl
    public static final String KEY_EXTRA_SHELL_ONE_HANDED = "extra_shell_one_handed";
    // See IShellTransitions.aidl
    public static final String KEY_EXTRA_SHELL_SHELL_TRANSITIONS =
            "extra_shell_shell_transitions";
    // See IStartingWindow.aidl
    public static final String KEY_EXTRA_SHELL_STARTING_WINDOW =
            "extra_shell_starting_window";
    // See IRecentTasks.aidl
    public static final String KEY_EXTRA_SHELL_RECENT_TASKS = "extra_shell_recent_tasks";
    // See IBackAnimation.aidl
    public static final String KEY_EXTRA_SHELL_BACK_ANIMATION = "extra_shell_back_animation";
    // See IDesktopMode.aidl
    public static final String KEY_EXTRA_SHELL_DESKTOP_MODE = "extra_shell_desktop_mode";
    // See IDragAndDrop.aidl
    public static final String KEY_EXTRA_SHELL_DRAG_AND_DROP = "extra_shell_drag_and_drop";
    // See IRecentsAnimationController.aidl
    public static final String KEY_EXTRA_SHELL_CAN_HAND_OFF_ANIMATION =
            "extra_shell_can_hand_off_animation";
}
+1 −2
Original line number Diff line number Diff line
@@ -32,7 +32,6 @@ import static com.android.window.flags.Flags.migratePredictiveBackTransition;
import static com.android.window.flags.Flags.predictiveBackSystemAnims;
import static com.android.window.flags.Flags.unifyBackNavigationTransition;
import static com.android.wm.shell.protolog.ShellProtoLogGroup.WM_SHELL_BACK_PREVIEW;
import static com.android.wm.shell.shared.ShellSharedConstants.KEY_EXTRA_SHELL_BACK_ANIMATION;

import android.annotation.NonNull;
import android.annotation.Nullable;
@@ -308,7 +307,7 @@ public class BackAnimationController implements RemoteCallable<BackAnimationCont
        setupAnimationDeveloperSettingsObserver(mContentResolver, mBgHandler);
        updateEnableAnimationFromFlags();
        createAdapter();
        mShellController.addExternalInterface(KEY_EXTRA_SHELL_BACK_ANIMATION,
        mShellController.addExternalInterface(IBackAnimation.DESCRIPTOR,
                this::createExternalInterface, this);
        mShellCommandHandler.addDumpCallback(this::dump, this);
        mShellController.addConfigurationChangeListener(this);
+1 −2
Original line number Diff line number Diff line
@@ -35,7 +35,6 @@ import static com.android.wm.shell.bubbles.Bubbles.DISMISS_PACKAGE_REMOVED;
import static com.android.wm.shell.bubbles.Bubbles.DISMISS_SHORTCUT_REMOVED;
import static com.android.wm.shell.bubbles.Bubbles.DISMISS_USER_CHANGED;
import static com.android.wm.shell.protolog.ShellProtoLogGroup.WM_SHELL_BUBBLES;
import static com.android.wm.shell.shared.ShellSharedConstants.KEY_EXTRA_SHELL_BUBBLES;

import android.annotation.BinderThread;
import android.annotation.NonNull;
@@ -522,7 +521,7 @@ public class BubbleController implements ConfigurationChangeListener,
        }

        mShellController.addConfigurationChangeListener(this);
        mShellController.addExternalInterface(KEY_EXTRA_SHELL_BUBBLES,
        mShellController.addExternalInterface(IBubbles.DESCRIPTOR,
                this::createExternalInterface, this);
        mShellCommandHandler.addDumpCallback(this::dump, this);
    }
+1 −2
Original line number Diff line number Diff line
@@ -104,7 +104,6 @@ import com.android.wm.shell.recents.RecentsTransitionHandler
import com.android.wm.shell.recents.RecentsTransitionStateListener
import com.android.wm.shell.recents.RecentsTransitionStateListener.RecentsTransitionState
import com.android.wm.shell.recents.RecentsTransitionStateListener.TRANSITION_STATE_NOT_RUNNING
import com.android.wm.shell.shared.ShellSharedConstants
import com.android.wm.shell.shared.TransitionUtil
import com.android.wm.shell.shared.annotations.ExternalThread
import com.android.wm.shell.shared.annotations.ShellMainThread
@@ -237,7 +236,7 @@ class DesktopTasksController(
        shellCommandHandler.addDumpCallback(this::dump, this)
        shellCommandHandler.addCommandCallback("desktopmode", desktopModeShellCommandHandler, this)
        shellController.addExternalInterface(
            ShellSharedConstants.KEY_EXTRA_SHELL_DESKTOP_MODE,
            IDesktopMode.DESCRIPTOR,
            { createExternalInterface() },
            this,
        )
+1 −3
Original line number Diff line number Diff line
@@ -31,8 +31,6 @@ import static android.view.WindowManager.LayoutParams.PRIVATE_FLAG_NO_MOVE_ANIMA
import static android.view.WindowManager.LayoutParams.SYSTEM_FLAG_SHOW_FOR_ALL_USERS;
import static android.view.WindowManager.LayoutParams.TYPE_APPLICATION_OVERLAY;

import static com.android.wm.shell.shared.ShellSharedConstants.KEY_EXTRA_SHELL_DRAG_AND_DROP;

import android.app.ActivityManager;
import android.app.ActivityTaskManager;
import android.app.PendingIntent;
@@ -167,7 +165,7 @@ public class DragAndDropController implements RemoteCallable<DragAndDropControll
        mMainExecutor.executeDelayed(() -> {
            mDisplayController.addDisplayWindowListener(this);
        }, 0);
        mShellController.addExternalInterface(KEY_EXTRA_SHELL_DRAG_AND_DROP,
        mShellController.addExternalInterface(IDragAndDrop.DESCRIPTOR,
                this::createExternalInterface, this);
        mShellTaskOrganizer.addTaskVanishedListener(this);
        mShellCommandHandler.addDumpCallback(this::dump, this);
Loading