mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-19 02:38:20 +00:00
Merge "NIU Actions and Recents UI updates on Go" into sc-dev
This commit is contained in:
@@ -24,10 +24,14 @@
|
||||
<LinearLayout
|
||||
android:id="@+id/action_buttons"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_height="@dimen/overview_actions_height"
|
||||
android:layout_gravity="top|center_horizontal"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<Space
|
||||
android:layout_width="@dimen/go_overview_button_width"
|
||||
android:layout_height="1dp" />
|
||||
|
||||
<Space
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="1dp"
|
||||
@@ -86,6 +90,10 @@
|
||||
android:layout_height="1dp"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<Space
|
||||
android:layout_width="@dimen/go_overview_button_width"
|
||||
android:layout_height="1dp" />
|
||||
|
||||
<!-- Will be enabled in a future version. -->
|
||||
<LinearLayout
|
||||
style="@style/GoOverviewActionButtonContainer"
|
||||
|
||||
@@ -23,4 +23,8 @@
|
||||
<dimen name="go_overview_button_height">60dp</dimen>
|
||||
<dimen name="go_overview_button_container_width">80dp</dimen>
|
||||
<dimen name="go_overview_button_caption_margin">8dp</dimen>
|
||||
<dimen name="overview_actions_height">96dp</dimen>
|
||||
<dimen name="overview_proactive_row_height">0dp</dimen>
|
||||
<dimen name="overview_proactive_row_bottom_margin">24dp</dimen>
|
||||
<dimen name="task_corner_radius_override">28dp</dimen>
|
||||
</resources>
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
</style>
|
||||
|
||||
<style name="GoOverviewActionButtonCaption">
|
||||
<item name="android:fontFamily">roboto-medium</item>
|
||||
<item name="android:fontFamily">sans-serif-medium</item>
|
||||
<item name="android:textSize">14dp</item>
|
||||
<item name="android:textColor">@color/go_overview_button_icon_color</item>
|
||||
<item name="android:lineHeight">20dp</item>
|
||||
|
||||
@@ -19,6 +19,8 @@
|
||||
<dimen name="task_thumbnail_icon_size_grid">32dp</dimen>
|
||||
<!-- For screens without rounded corners -->
|
||||
<dimen name="task_corner_radius_small">2dp</dimen>
|
||||
<!-- For Launchers that want to override the default dialog corner radius -->
|
||||
<dimen name="task_corner_radius_override">-1dp</dimen>
|
||||
|
||||
<dimen name="overview_proactive_row_height">48dp</dimen>
|
||||
<dimen name="overview_proactive_row_bottom_margin">16dp</dimen>
|
||||
|
||||
@@ -18,6 +18,7 @@ package com.android.quickstep.util;
|
||||
import static com.android.systemui.shared.system.QuickStepContract.supportsRoundedCornersOnWindows;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.res.Resources;
|
||||
|
||||
import com.android.launcher3.R;
|
||||
import com.android.launcher3.util.Themes;
|
||||
@@ -25,8 +26,13 @@ import com.android.launcher3.util.Themes;
|
||||
public class TaskCornerRadius {
|
||||
|
||||
public static float get(Context context) {
|
||||
return supportsRoundedCornersOnWindows(context.getResources()) ?
|
||||
Themes.getDialogCornerRadius(context):
|
||||
context.getResources().getDimension(R.dimen.task_corner_radius_small);
|
||||
Resources resources = context.getResources();
|
||||
if (!supportsRoundedCornersOnWindows(resources)) {
|
||||
return resources.getDimension(R.dimen.task_corner_radius_small);
|
||||
}
|
||||
|
||||
float overriddenRadius =
|
||||
resources.getDimension(R.dimen.task_corner_radius_override);
|
||||
return (overriddenRadius > 0) ? overriddenRadius : Themes.getDialogCornerRadius(context);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user