Loading core/java/android/window/IDisplayAreaOrganizer.aidl 0 → 100644 +28 −0 Original line number Diff line number Diff line /* * Copyright (C) 2020 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package android.window; import android.window.IWindowContainer; /** * Interface for WindowManager to delegate control of display areas. * {@hide} */ oneway interface IDisplayAreaOrganizer { void onDisplayAreaAppeared(in IWindowContainer displayArea); void onDisplayAreaVanished(in IWindowContainer displayArea); } core/java/android/window/IDisplayAreaOrganizerController.aidl 0 → 100644 +26 −0 Original line number Diff line number Diff line /** * Copyright (c) 2020, The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package android.window; import android.window.IDisplayAreaOrganizer; /** @hide */ interface IDisplayAreaOrganizerController { /** Register a DisplayAreaOrganizer to manage display areas for a given feature. */ void registerOrganizer(in IDisplayAreaOrganizer organizer, int displayAreaFeature); } core/java/android/window/ITaskOrganizer.aidl +2 −2 Original line number Diff line number Diff line Loading @@ -25,8 +25,8 @@ import android.window.IWindowContainer; * {@hide} */ oneway interface ITaskOrganizer { void taskAppeared(in ActivityManager.RunningTaskInfo taskInfo); void taskVanished(in ActivityManager.RunningTaskInfo taskInfo); void onTaskAppeared(in ActivityManager.RunningTaskInfo taskInfo); void onTaskVanished(in ActivityManager.RunningTaskInfo taskInfo); /** * Will fire when core attributes of a Task's info change. Relevant properties include the Loading core/java/android/window/IWindowOrganizerController.aidl +4 −0 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ package android.window; import android.window.IDisplayAreaOrganizerController; import android.window.ITaskOrganizerController; import android.window.IWindowContainerTransactionCallback; import android.window.WindowContainerTransaction; Loading Loading @@ -43,4 +44,7 @@ interface IWindowOrganizerController { /** @return An interface enabling the management of task organizers. */ ITaskOrganizerController getTaskOrganizerController(); /** @return An interface enabling the management of display area organizers. */ IDisplayAreaOrganizerController getDisplayAreaOrganizerController(); } core/java/android/window/WindowOrganizer.java +44 −0 Original line number Diff line number Diff line Loading @@ -152,6 +152,50 @@ public class WindowOrganizer { } } }; } /** Class for organizing display areas. */ public static class DisplayAreaOrganizer { public static final int FEATURE_UNDEFINED = -1; public static final int FEATURE_SYSTEM_FIRST = 0; // The Root display area on a display public static final int FEATURE_ROOT = FEATURE_SYSTEM_FIRST; // Display area hosting the task container. public static final int FEATURE_TASK_CONTAINER = FEATURE_SYSTEM_FIRST + 1; // Display area hosting non-activity window tokens. public static final int FEATURE_WINDOW_TOKENS = FEATURE_SYSTEM_FIRST + 2; public static final int FEATURE_SYSTEM_LAST = 10_000; // Vendor specific display area definition can start with this value. public static final int FEATURE_VENDOR_FIRST = FEATURE_SYSTEM_LAST + 1; /** @hide */ @RequiresPermission(android.Manifest.permission.MANAGE_ACTIVITY_STACKS) public static void registerOrganizer( IDisplayAreaOrganizer organizer, int displayAreaFeature) throws RemoteException { getController().registerOrganizer(organizer, displayAreaFeature); } /** @hide */ private static IDisplayAreaOrganizerController getController() { return IDisplayAreaOrganizerControllerSingleton.get(); } private static final Singleton<IDisplayAreaOrganizerController> IDisplayAreaOrganizerControllerSingleton = new Singleton<IDisplayAreaOrganizerController>() { @Override protected IDisplayAreaOrganizerController create() { try { return getWindowOrganizerController() .getDisplayAreaOrganizerController(); } catch (RemoteException e) { return null; } } }; } } Loading
core/java/android/window/IDisplayAreaOrganizer.aidl 0 → 100644 +28 −0 Original line number Diff line number Diff line /* * Copyright (C) 2020 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package android.window; import android.window.IWindowContainer; /** * Interface for WindowManager to delegate control of display areas. * {@hide} */ oneway interface IDisplayAreaOrganizer { void onDisplayAreaAppeared(in IWindowContainer displayArea); void onDisplayAreaVanished(in IWindowContainer displayArea); }
core/java/android/window/IDisplayAreaOrganizerController.aidl 0 → 100644 +26 −0 Original line number Diff line number Diff line /** * Copyright (c) 2020, The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package android.window; import android.window.IDisplayAreaOrganizer; /** @hide */ interface IDisplayAreaOrganizerController { /** Register a DisplayAreaOrganizer to manage display areas for a given feature. */ void registerOrganizer(in IDisplayAreaOrganizer organizer, int displayAreaFeature); }
core/java/android/window/ITaskOrganizer.aidl +2 −2 Original line number Diff line number Diff line Loading @@ -25,8 +25,8 @@ import android.window.IWindowContainer; * {@hide} */ oneway interface ITaskOrganizer { void taskAppeared(in ActivityManager.RunningTaskInfo taskInfo); void taskVanished(in ActivityManager.RunningTaskInfo taskInfo); void onTaskAppeared(in ActivityManager.RunningTaskInfo taskInfo); void onTaskVanished(in ActivityManager.RunningTaskInfo taskInfo); /** * Will fire when core attributes of a Task's info change. Relevant properties include the Loading
core/java/android/window/IWindowOrganizerController.aidl +4 −0 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ package android.window; import android.window.IDisplayAreaOrganizerController; import android.window.ITaskOrganizerController; import android.window.IWindowContainerTransactionCallback; import android.window.WindowContainerTransaction; Loading Loading @@ -43,4 +44,7 @@ interface IWindowOrganizerController { /** @return An interface enabling the management of task organizers. */ ITaskOrganizerController getTaskOrganizerController(); /** @return An interface enabling the management of display area organizers. */ IDisplayAreaOrganizerController getDisplayAreaOrganizerController(); }
core/java/android/window/WindowOrganizer.java +44 −0 Original line number Diff line number Diff line Loading @@ -152,6 +152,50 @@ public class WindowOrganizer { } } }; } /** Class for organizing display areas. */ public static class DisplayAreaOrganizer { public static final int FEATURE_UNDEFINED = -1; public static final int FEATURE_SYSTEM_FIRST = 0; // The Root display area on a display public static final int FEATURE_ROOT = FEATURE_SYSTEM_FIRST; // Display area hosting the task container. public static final int FEATURE_TASK_CONTAINER = FEATURE_SYSTEM_FIRST + 1; // Display area hosting non-activity window tokens. public static final int FEATURE_WINDOW_TOKENS = FEATURE_SYSTEM_FIRST + 2; public static final int FEATURE_SYSTEM_LAST = 10_000; // Vendor specific display area definition can start with this value. public static final int FEATURE_VENDOR_FIRST = FEATURE_SYSTEM_LAST + 1; /** @hide */ @RequiresPermission(android.Manifest.permission.MANAGE_ACTIVITY_STACKS) public static void registerOrganizer( IDisplayAreaOrganizer organizer, int displayAreaFeature) throws RemoteException { getController().registerOrganizer(organizer, displayAreaFeature); } /** @hide */ private static IDisplayAreaOrganizerController getController() { return IDisplayAreaOrganizerControllerSingleton.get(); } private static final Singleton<IDisplayAreaOrganizerController> IDisplayAreaOrganizerControllerSingleton = new Singleton<IDisplayAreaOrganizerController>() { @Override protected IDisplayAreaOrganizerController create() { try { return getWindowOrganizerController() .getDisplayAreaOrganizerController(); } catch (RemoteException e) { return null; } } }; } }