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

Commit 304a13b2 authored by Alan Viverette's avatar Alan Viverette
Browse files

Update alert dialog styling to match Material spec

BUG: 17415772
Change-Id: I8dc407adb2a338c1288ca9d50e921d9fe3496c22
parent ce78347c
Loading
Loading
Loading
Loading
+11 −18
Original line number Diff line number Diff line
@@ -33,8 +33,8 @@
            android:gravity="center_vertical|start"
            android:paddingStart="@dimen/alert_dialog_padding_material"
            android:paddingEnd="@dimen/alert_dialog_padding_material"
            android:paddingTop="@dimen/alert_dialog_padding_material"
            android:paddingBottom="8dip">
            android:paddingTop="@dimen/alert_dialog_padding_top_material"
            android:paddingBottom="12dip">
            <ImageView android:id="@+id/icon"
                android:layout_width="32dip"
                android:layout_height="32dip"
@@ -67,9 +67,7 @@
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:paddingStart="@dimen/alert_dialog_padding_material"
                android:paddingEnd="@dimen/alert_dialog_padding_material"
                android:paddingTop="@dimen/alert_dialog_padding_material"
                android:paddingBottom="@dimen/alert_dialog_padding_material" />
                android:paddingEnd="@dimen/alert_dialog_padding_material" />
        </ScrollView>
    </LinearLayout>

@@ -77,7 +75,7 @@
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_weight="1"
        android:minHeight="64dp">
        android:minHeight="48dp">
        <FrameLayout android:id="@+id/custom"
            android:layout_width="match_parent"
            android:layout_height="wrap_content" />
@@ -89,15 +87,14 @@
        android:layout_height="wrap_content"
        android:layoutDirection="locale"
        android:orientation="horizontal"
        android:paddingStart="6dp"
        android:paddingEnd="6dp"
        android:paddingBottom="6dp">
        android:paddingStart="12dp"
        android:paddingEnd="12dp"
        android:paddingTop="8dp"
        android:paddingBottom="8dp">
        <Button android:id="@+id/button3"
            style="?attr/buttonBarNeutralButtonStyle"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:maxLines="2"
            android:minHeight="@dimen/alert_dialog_button_bar_height" />
            android:layout_height="wrap_content" />
        <Space
            android:layout_width="0dp"
            android:layout_height="0dp"
@@ -106,14 +103,10 @@
        <Button android:id="@+id/button2"
            style="?attr/buttonBarNegativeButtonStyle"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:maxLines="2"
            android:minHeight="@dimen/alert_dialog_button_bar_height" />
            android:layout_height="wrap_content" />
        <Button android:id="@+id/button1"
            style="?attr/buttonBarPositiveButtonStyle"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:maxLines="2"
            android:minHeight="@dimen/alert_dialog_button_bar_height" />
            android:layout_height="wrap_content" />
    </LinearLayout>
</LinearLayout>
+6 −13
Original line number Diff line number Diff line
@@ -17,32 +17,25 @@

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="wrap_content"
    android:layout_height="match_parent">
    <ProgressBar android:id="@+id/progress"
        style="?android:attr/progressBarStyleHorizontal"
    android:layout_height="match_parent"
    android:paddingStart="@dimen/alert_dialog_padding_material"
    android:paddingEnd="@dimen/alert_dialog_padding_material">
    <ProgressBar
        android:id="@+id/progress"
        style="?attr/progressBarStyleHorizontal"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_marginTop="16dip"
        android:layout_marginBottom="1dip"
        android:layout_marginStart="16dip"
        android:layout_marginEnd="16dip"
        android:layout_centerHorizontal="true" />
    <TextView
        android:id="@+id/progress_percent"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:paddingBottom="16dip"
        android:layout_marginStart="16dip"
        android:layout_marginEnd="16dip"
        android:layout_alignParentStart="true"
        android:layout_below="@id/progress" />
    <TextView
        android:id="@+id/progress_number"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:paddingBottom="16dip"
        android:layout_marginStart="16dip"
        android:layout_marginEnd="16dip"
        android:layout_alignParentEnd="true"
        android:layout_below="@id/progress" />
</RelativeLayout>
+4 −4
Original line number Diff line number Diff line
@@ -23,17 +23,17 @@ This is a custom layout for a dialog.
    android:fitsSystemWindows="true">
    <FrameLayout android:id="@android:id/title_container"
        android:layout_width="match_parent"
        android:layout_height="?android:attr/windowTitleSize"
        android:layout_height="?attr/windowTitleSize"
        android:layout_weight="0"
        android:gravity="center_vertical|start"
        style="?android:attr/windowTitleBackgroundStyle" />
        style="?attr/windowTitleBackgroundStyle" />
    <FrameLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_weight="1"
        android:orientation="vertical"
        android:foreground="?android:attr/windowContentOverlay">
        <FrameLayout android:id="@android:id/content"
        android:foreground="?attr/windowContentOverlay">
        <FrameLayout android:id="@id/content"
            android:layout_width="match_parent"
            android:layout_height="match_parent" />
    </FrameLayout>
+7 −7
Original line number Diff line number Diff line
@@ -28,16 +28,16 @@ enabled.
        android:layout_height="wrap_content"
        android:orientation="horizontal"
        android:gravity="center_vertical"
        android:paddingStart="16dip"
        android:paddingEnd="16dip"
        android:paddingTop="16dip">
        android:paddingStart="@dimen/alert_dialog_padding_material"
        android:paddingEnd="@dimen/alert_dialog_padding_material"
        android:paddingTop="@dimen/alert_dialog_padding_material">
        <ImageView android:id="@+id/left_icon"
            android:layout_width="32dip"
            android:layout_height="32dip"
            android:scaleType="fitCenter"
            android:layout_marginEnd="8dip" />
        <TextView android:id="@android:id/title"
            style="?android:attr/windowTitleStyle"
        <TextView android:id="@id/title"
            style="?attr/windowTitleStyle"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_weight="0" />
@@ -52,8 +52,8 @@ enabled.
        android:layout_width="match_parent" android:layout_height="wrap_content"
        android:layout_weight="1"
        android:orientation="vertical"
        android:foreground="?android:attr/windowContentOverlay">
        <FrameLayout android:id="@android:id/content"
        android:foreground="?attr/windowContentOverlay">
        <FrameLayout android:id="@id/content"
            android:layout_width="match_parent"
            android:layout_height="match_parent" />
    </FrameLayout>
+5 −5
Original line number Diff line number Diff line
@@ -29,15 +29,15 @@ enabled.
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:textAlignment="viewStart"
        android:paddingStart="16dip"
        android:paddingEnd="16dip"
        android:paddingTop="16dip" />
        android:paddingStart="@dimen/alert_dialog_padding_material"
        android:paddingEnd="@dimen/alert_dialog_padding_material"
        android:paddingTop="@dimen/alert_dialog_padding_top_material" />
    <FrameLayout
        android:layout_width="match_parent" android:layout_height="wrap_content"
        android:layout_weight="1"
        android:orientation="vertical"
        android:foreground="?android:attr/windowContentOverlay">
        <FrameLayout android:id="@android:id/content"
        android:foreground="?attr/windowContentOverlay">
        <FrameLayout android:id="@id/content"
            android:layout_width="match_parent"
            android:layout_height="match_parent" />
    </FrameLayout>
Loading