| OLD | NEW |
| 1 <?xml version="1.0" encoding="utf-8"?> | 1 <?xml version="1.0" encoding="utf-8"?> |
| 2 <!-- Copyright 2015 The Chromium Authors. All rights reserved. | 2 <!-- Copyright 2015 The Chromium Authors. All rights reserved. |
| 3 Use of this source code is governed by a BSD-style license that can be | 3 Use of this source code is governed by a BSD-style license that can be |
| 4 found in the LICENSE file. --> | 4 found in the LICENSE file. --> |
| 5 | 5 |
| 6 <org.chromium.chrome.browser.widget.PaddedFrameLayout | 6 <org.chromium.chrome.browser.widget.PaddedFrameLayout |
| 7 xmlns:android="http://schemas.android.com/apk/res/android" | 7 xmlns:android="http://schemas.android.com/apk/res/android" |
| 8 xmlns:chrome="http://schemas.android.com/apk/res-auto" | 8 xmlns:chrome="http://schemas.android.com/apk/res-auto" |
| 9 android:background="#c000" | 9 android:background="#c000" |
| 10 chrome:maxChildHeight="@dimen/data_reduction_promo_screen_height" | 10 chrome:maxChildHeight="@dimen/data_reduction_promo_screen_height" |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 android:layout_alignParentTop="true" | 28 android:layout_alignParentTop="true" |
| 29 android:background="?android:attr/selectableItemBackground" | 29 android:background="?android:attr/selectableItemBackground" |
| 30 android:contentDescription="@string/close" | 30 android:contentDescription="@string/close" |
| 31 android:src="@drawable/btn_close" /> | 31 android:src="@drawable/btn_close" /> |
| 32 | 32 |
| 33 <LinearLayout | 33 <LinearLayout |
| 34 android:id="@+id/data_reduction_promo_text" | 34 android:id="@+id/data_reduction_promo_text" |
| 35 android:layout_height="wrap_content" | 35 android:layout_height="wrap_content" |
| 36 android:layout_width="match_parent" | 36 android:layout_width="match_parent" |
| 37 android:layout_below="@+id/close_button" | 37 android:layout_below="@+id/close_button" |
| 38 android:layout_marginTop="8dp" | 38 android:layout_marginTop="16dp" |
| 39 android:orientation="vertical" | 39 android:orientation="vertical" |
| 40 android:paddingEnd="24dp" | 40 android:paddingEnd="24dp" |
| 41 android:paddingStart="24dp" > | 41 android:paddingStart="24dp" > |
| 42 | 42 |
| 43 <ImageView | 43 <ImageView |
| 44 android:layout_height="wrap_content" | 44 android:layout_height="wrap_content" |
| 45 android:layout_width="match_parent" | 45 android:layout_width="wrap_content" |
| 46 android:layout_marginBottom="24dp" | 46 android:layout_gravity="center_horizontal" |
| 47 android:layout_marginBottom="@dimen/data_reduction_promo_ill
ustration_margin_bottom" |
| 47 android:adjustViewBounds="true" | 48 android:adjustViewBounds="true" |
| 48 android:contentDescription="@null" | 49 android:contentDescription="@null" |
| 49 android:gravity="center" | |
| 50 android:src="@drawable/data_reduction_illustration" /> | 50 android:src="@drawable/data_reduction_illustration" /> |
| 51 | 51 |
| 52 <TextView | 52 <TextView |
| 53 android:layout_height="wrap_content" | 53 android:layout_height="wrap_content" |
| 54 android:layout_width="match_parent" | 54 android:layout_width="match_parent" |
| 55 android:layout_marginBottom="8dp" | 55 android:layout_marginBottom="8dp" |
| 56 android:text="@string/data_reduction_promo_title" | 56 android:text="@string/data_reduction_promo_title" |
| 57 android:textColor="@color/default_text_color" | 57 android:textColor="@color/default_text_color" |
| 58 android:textSize="@dimen/data_reduction_promo_title_text_siz
e" /> | 58 android:textSize="@dimen/data_reduction_promo_title_text_siz
e" /> |
| 59 | 59 |
| 60 <TextView | 60 <TextView |
| 61 android:layout_height="wrap_content" | 61 android:layout_height="wrap_content" |
| 62 android:layout_width="match_parent" | 62 android:layout_width="match_parent" |
| 63 android:lineSpacingMultiplier="1.3" | 63 android:lineSpacingMultiplier="1.3" |
| 64 android:text="@string/data_reduction_promo_summary" | 64 android:text="@string/data_reduction_promo_summary" |
| 65 android:textColor="#646464" | 65 android:textColor="#646464" |
| 66 android:textSize="@dimen/data_reduction_promo_normal_text_si
ze" /> | 66 android:textSize="@dimen/data_reduction_promo_normal_text_si
ze" /> |
| 67 </LinearLayout> | 67 </LinearLayout> |
| 68 | 68 |
| 69 <LinearLayout | 69 <FrameLayout |
| 70 android:layout_height="wrap_content" | 70 android:layout_height="wrap_content" |
| 71 android:layout_width="match_parent" | 71 android:layout_width="match_parent" |
| 72 android:layout_alignParentBottom="true" | 72 android:layout_alignParentBottom="true" |
| 73 android:layout_below="@id/data_reduction_promo_text" | 73 android:layout_below="@id/data_reduction_promo_text" > |
| 74 android:padding="16dp" | 74 |
| 75 android:clipToPadding="false" | 75 <!-- The FrameLayout must have layout_below so that the buttons
don't |
| 76 android:gravity="end|bottom" | 76 overlap the text. This causes the FrameLayout to extend fro
m |
| 77 android:orientation="horizontal" > | 77 data_reduction_promo_text to the bottom of the RelativeLayo
ut. |
| 78 <org.chromium.ui.widget.ButtonCompat | 78 In order for the buttons to adjust their height when the sc
reen |
| 79 android:id="@+id/no_thanks_button" | 79 size causes multiple lines of text, but not be the size of
the |
| 80 empty space between the text and bottom of the promo we nee
d |
| 81 this second LinearLayout. --> |
| 82 <LinearLayout |
| 80 android:layout_height="wrap_content" | 83 android:layout_height="wrap_content" |
| 81 android:layout_width="wrap_content" | 84 android:layout_width="match_parent" |
| 82 android:layout_marginEnd="8dp" | 85 android:layout_gravity="bottom" |
| 83 android:minHeight="40dp" | 86 android:orientation="horizontal" |
| 84 android:text="@string/no_thanks" | 87 android:clipToPadding="false" |
| 85 android:textColor="@color/light_normal_color" | 88 android:padding="16dp" |
| 86 android:textSize="@dimen/data_reduction_promo_button_text_si
ze" | 89 android:gravity="end" > |
| 87 chrome:buttonColor="#FFFFFF" /> | 90 |
| 88 <org.chromium.ui.widget.ButtonCompat | 91 <org.chromium.ui.widget.ButtonCompat |
| 89 android:id="@+id/enable_button" | 92 android:id="@+id/no_thanks_button" |
| 90 android:layout_height="wrap_content" | 93 android:layout_height="match_parent" |
| 91 android:layout_width="wrap_content" | 94 android:layout_width="wrap_content" |
| 92 android:minHeight="40dp" | 95 android:layout_marginEnd="8dp" |
| 93 android:text="@string/data_reduction_enable_button" | 96 android:layout_weight="1" |
| 94 android:textColor="#FFFFFF" | 97 android:minHeight="40dp" |
| 95 android:textSize="@dimen/data_reduction_promo_button_text_si
ze" | 98 android:text="@string/no_thanks" |
| 96 chrome:buttonColor="@color/light_active_color" /> | 99 android:textColor="@color/light_normal_color" |
| 97 </LinearLayout> | 100 android:textSize="@dimen/data_reduction_promo_button_tex
t_size" |
| 101 chrome:buttonColor="#FFFFFF" |
| 102 style="@style/ButtonCompatBorderless" /> |
| 103 |
| 104 <org.chromium.ui.widget.ButtonCompat |
| 105 android:id="@+id/enable_button" |
| 106 android:layout_height="match_parent" |
| 107 android:layout_width="wrap_content" |
| 108 android:layout_weight="1" |
| 109 android:elevation="0dp" |
| 110 android:minHeight="40dp" |
| 111 android:text="@string/data_reduction_enable_button" |
| 112 android:textColor="#FFFFFF" |
| 113 android:textSize="@dimen/data_reduction_promo_button_tex
t_size" |
| 114 chrome:buttonColor="@color/light_active_color" /> |
| 115 </LinearLayout> |
| 116 </FrameLayout> |
| 98 </RelativeLayout> | 117 </RelativeLayout> |
| 99 </ScrollView> | 118 </ScrollView> |
| 100 </org.chromium.chrome.browser.widget.PaddedFrameLayout> | 119 </org.chromium.chrome.browser.widget.PaddedFrameLayout> |
| OLD | NEW |