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

Commit 1ef16a76 authored by Anton Potapov's avatar Anton Potapov
Browse files

Update AppSwitcher visuals

Switched from using GlobalActionsPopupMenu in Home Controls to a custom one due to the amount of customization required

Test: manual on tablet, foldable, and phone. RTL and LTR layouts
Fixes: 266407603
Change-Id: I58808fc663855a7ae0f37a2edc8587c939d03ca1
parent d569a8b1
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -23,7 +23,7 @@
    <item
        android:drawable="@drawable/ic_ksh_key_down"
        android:gravity="end|bottom"
        android:paddingBottom="6dp"
        android:bottom="4dp"
        android:width="24dp"
        android:height="24dp"
        android:end="12dp" />
+22 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright (C) 2023 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.
  -->

<shape xmlns:android="http://schemas.android.com/apk/res/android"
    android:shape="rectangle">
    <solid android:color="@color/transparent" />
    <corners android:radius="@dimen/control_popup_corner_radius" />
</shape>
+31 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright (C) 2023 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.
  -->

<selector xmlns:android="http://schemas.android.com/apk/res/android">
    <item android:state_pressed="true">
        <shape android:shape="rectangle">
            <corners android:radius="@dimen/control_popup_item_corner_radius" />
            <solid android:color="#303030" />
        </shape>
    </item>
    <item>
        <shape android:shape="rectangle">
            <corners android:radius="@dimen/control_popup_item_corner_radius" />
            <solid android:color="#1f1f1f" />
        </shape>
    </item>
</selector>
+21 −26
Original line number Diff line number Diff line
@@ -13,33 +13,28 @@
  ~ See the License for the specific language governing permissions and
  ~ limitations under the License.
  -->
<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:paddingVertical="@dimen/control_spinner_padding_vertical"
    android:paddingHorizontal="@dimen/control_spinner_padding_horizontal">

  <LinearLayout
    android:layout_height="@dimen/control_popup_item_height"
    android:background="@drawable/controls_popup_item_background"
    android:gravity="center_vertical|start"
    android:orientation="horizontal"
      android:layout_width="match_parent"
      android:layout_height="wrap_content"
      android:gravity="center">
    android:paddingStart="@dimen/control_popup_item_padding"
    android:paddingEnd="@dimen/control_popup_item_padding">

  <ImageView
      android:id="@+id/app_icon"
        android:layout_gravity="center"
      android:layout_width="@dimen/controls_header_app_icon_size"
      android:layout_height="@dimen/controls_header_app_icon_size"
      android:layout_marginEnd="@dimen/control_popup_item_padding"
      android:contentDescription="@null"
        android:layout_marginEnd="10dp" />
      tools:src="@drawable/ic_android" />

  <TextView
        style="@style/Control.Spinner.Item"
      android:id="@+id/controls_spinner_item"
      style="@style/Control.Spinner.Item"
      android:layout_width="wrap_content"
      android:layout_height="wrap_content"
        android:layout_gravity="center" />
  </LinearLayout>

      tools:text="Android" />
</LinearLayout>
+2 −4
Original line number Diff line number Diff line
@@ -50,11 +50,9 @@
        <LinearLayout
            android:id="@+id/controls_header"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:layout_gravity="center"
            android:layout_height="match_parent"
            android:layout_weight="1"
            android:gravity="center"
            android:minHeight="48dp"
            android:orientation="horizontal">

            <TextView
@@ -64,7 +62,7 @@
                android:layout_height="wrap_content"
                android:layout_gravity="center"
                android:clickable="false"
                tools:text="Test app" />
                tools:text="@tools:sample/lorem" />
        </LinearLayout>

        <ImageView
Loading