mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-20 03:08:19 +00:00
This CL refactors Overview Actions View so that a separate view, R.id.group_action_buttons, is used for buttons related to grouped tasks. This also changes the way visibility is handled with actions buttons -- instead of all buttons living on one bar and being toggled on and off, sometimes the whole bar is toggled on and off (to change from single task actions to group actions and vice versa). This prevents the same view from having its visibility changed twice in in one layout and causing the wrong visibility to be rendered. Fixes: 333844287 Test: Manual Flag: ACONFIG com.android.wm.shell.enable_app_pairs NEXTFOOD Change-Id: I1b6be4637ac8c8d424e7633c437fca376ecdd757
68 lines
2.7 KiB
XML
68 lines
2.7 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!--
|
|
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.
|
|
-->
|
|
<com.android.quickstep.views.OverviewActionsView xmlns:android="http://schemas.android.com/apk/res/android"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:layout_gravity="center_horizontal|bottom">
|
|
|
|
<LinearLayout
|
|
android:id="@+id/action_buttons"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="@dimen/overview_actions_height"
|
|
android:layout_gravity="bottom|center_horizontal"
|
|
android:orientation="horizontal">
|
|
|
|
<Button
|
|
android:id="@+id/action_screenshot"
|
|
style="@style/OverviewActionButton"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:drawableStart="@drawable/ic_screenshot"
|
|
android:text="@string/action_screenshot"
|
|
android:theme="@style/ThemeControlHighlightWorkspaceColor" />
|
|
|
|
<Button
|
|
android:id="@+id/action_split"
|
|
style="@style/OverviewActionButton"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginStart="@dimen/overview_actions_button_spacing"
|
|
android:text="@string/action_split"
|
|
android:theme="@style/ThemeControlHighlightWorkspaceColor"
|
|
android:visibility="gone" />
|
|
|
|
</LinearLayout>
|
|
|
|
<LinearLayout
|
|
android:id="@+id/group_action_buttons"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="@dimen/overview_actions_height"
|
|
android:layout_gravity="bottom|center_horizontal"
|
|
android:orientation="horizontal"
|
|
android:visibility="gone">
|
|
|
|
<Button
|
|
android:id="@+id/action_save_app_pair"
|
|
style="@style/OverviewActionButton"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:text="@string/action_save_app_pair"
|
|
android:theme="@style/ThemeControlHighlightWorkspaceColor" />
|
|
|
|
</LinearLayout>
|
|
|
|
</com.android.quickstep.views.OverviewActionsView> |