Commit 190dade0 authored by Xinghui Lu's avatar Xinghui Lu Committed by Commit Bot

Fix arrow direction in RTL layout.

In RTL layout, the aux button of the
RadioButtonWithDescriptionAndAuxButton widget is pointing to the
wrong direction. Fix it by setting a different rotation degree in
RTL layout. Also rename ic_expand_more_right_black_24dp.xml to
ic_expand_more_horizontal_black_24dp.xml to reduce confusion.

Before: http://screen/h3HRvuXJgJF
After: http://screen/8LDgx4Z8m9U

Bug: 1105998
Change-Id: I2856b64d66deb7afccc00e1ed2c66e54285848f1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2327394Reviewed-by: default avatarTheresa  <twellington@chromium.org>
Commit-Queue: Xinghui Lu <xinghuilu@chromium.org>
Cr-Commit-Position: refs/heads/master@{#793750}
parent 98cbb0e1
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:paddingStart="@dimen/radio_button_with_description_and_aux_button_spacing" android:paddingStart="@dimen/radio_button_with_description_and_aux_button_spacing"
android:paddingEnd="@dimen/radio_button_with_description_lateral_padding" android:paddingEnd="@dimen/radio_button_with_description_lateral_padding"
android:src="@drawable/ic_expand_more_right_black_24dp" android:src="@drawable/ic_expand_more_horizontal_black_24dp"
android:background="?android:attr/selectableItemBackground" android:background="?android:attr/selectableItemBackground"
app:tint="@color/default_icon_color_tint_list"/> app:tint="@color/default_icon_color_tint_list"/>
</LinearLayout> </LinearLayout>
...@@ -165,13 +165,14 @@ android_resources("ui_java_resources") { ...@@ -165,13 +165,14 @@ android_resources("ui_java_resources") {
"java/res/drawable-xxxhdpi/ic_expand_more_black_24dp.png", "java/res/drawable-xxxhdpi/ic_expand_more_black_24dp.png",
"java/res/drawable-xxxhdpi/popup_bg.9.png", "java/res/drawable-xxxhdpi/popup_bg.9.png",
"java/res/drawable/drag_handlebar.xml", "java/res/drawable/drag_handlebar.xml",
"java/res/drawable/ic_expand_more_right_black_24dp.xml", "java/res/drawable/ic_expand_more_horizontal_black_24dp.xml",
"java/res/drawable/popup_bg_tinted.xml", "java/res/drawable/popup_bg_tinted.xml",
"java/res/font/accent_font.xml", "java/res/font/accent_font.xml",
"java/res/layout/dropdown_footer_wrapper_jellybean.xml", "java/res/layout/dropdown_footer_wrapper_jellybean.xml",
"java/res/layout/dropdown_item.xml", "java/res/layout/dropdown_item.xml",
"java/res/layout/dropdown_window.xml", "java/res/layout/dropdown_window.xml",
"java/res/values-ldrtl/dimens.xml", "java/res/values-ldrtl/dimens.xml",
"java/res/values-ldrtl/values.xml",
"java/res/values-night/colors.xml", "java/res/values-night/colors.xml",
"java/res/values-night/dimens.xml", "java/res/values-night/dimens.xml",
"java/res/values-sw600dp/values.xml", "java/res/values-sw600dp/values.xml",
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
found in the LICENSE file. --> found in the LICENSE file. -->
<rotate xmlns:android="http://schemas.android.com/apk/res/android" <rotate xmlns:android="http://schemas.android.com/apk/res/android"
android:fromDegrees="270" android:fromDegrees="@integer/expand_more_horizontal_rotation_degree"
android:toDegrees="270" android:toDegrees="@integer/expand_more_horizontal_rotation_degree"
android:drawable="@drawable/ic_expand_more_black_24dp"> android:drawable="@drawable/ic_expand_more_black_24dp">
</rotate> </rotate>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright 2020 The Chromium Authors. All rights reserved.
Use of this source code is governed by a BSD-style license that can be
found in the LICENSE file.
-->
<resources xmlns:tools="http://schemas.android.com/tools">
<!-- Expand more -->
<integer name="expand_more_horizontal_rotation_degree"
tools:ignore="UnusedResources">90</integer>
</resources>
...@@ -9,4 +9,7 @@ ...@@ -9,4 +9,7 @@
<!-- Whether the device is a phone, tablet or large tablet. Used to determine which resources <!-- Whether the device is a phone, tablet or large tablet. Used to determine which resources
the OS loaded. --> the OS loaded. -->
<integer name="min_screen_width_bucket">1</integer> <integer name="min_screen_width_bucket">1</integer>
<!-- Expand more -->
<integer name="expand_more_horizontal_rotation_degree">270</integer>
</resources> </resources>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment