• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (C) 2016 The Android Open Source Project
3
4     Licensed under the Apache License, Version 2.0 (the "License");
5     you may not use this file except in compliance with the License.
6     You may obtain a copy of the License at
7
8          http://www.apache.org/licenses/LICENSE-2.0
9
10     Unless required by applicable law or agreed to in writing, software
11     distributed under the License is distributed on an "AS IS" BASIS,
12     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13     See the License for the specific language governing permissions and
14     limitations under the License.
15-->
16
17<com.android.settings.localepicker.LocaleDragCell
18    xmlns:android="http://schemas.android.com/apk/res/android"
19    xmlns:app="http://schemas.android.com/apk/res-auto"
20    android:layout_width="match_parent"
21    android:layout_height="wrap_content"
22    android:minHeight="?android:listPreferredItemHeight"
23    android:background="?android:colorBackground"
24    android:layout_marginTop="12dp"
25    android:layout_marginBottom="12dp"
26    android:layoutDirection="locale"
27    android:textDirection="locale">
28
29    <LinearLayout
30        android:id="@+id/numberLayout"
31        android:layout_width="wrap_content"
32        android:layout_height="wrap_content"
33        android:layout_centerVertical="true"
34        android:gravity="center_vertical|center_horizontal"
35        android:paddingStart="?android:attr/listPreferredItemPaddingStart">
36        <CheckBox
37            android:id="@+id/checkbox"
38            style="@style/LanguageCheckboxAndLabel"
39            android:layout_marginRight="0dp"
40            android:minWidth="24dp"
41            android:paddingEnd="-8dp"/>
42
43        <TextView
44            android:id="@+id/miniLabel"
45            style="@style/LanguageCheckboxAndLabel"
46            android:textColor="?android:attr/colorAccent"
47            android:minWidth="24dp"
48            android:gravity="center_vertical|center_horizontal"/>
49    </LinearLayout>
50
51    <androidx.constraintlayout.widget.ConstraintLayout
52        android:layout_width="wrap_content"
53        android:layout_height="wrap_content"
54        android:minHeight="?android:listPreferredItemHeight"
55        android:layout_toStartOf="@+id/dragHandle"
56        android:layout_toEndOf="@+id/numberLayout"
57        android:paddingStart="32dp">
58        <LinearLayout
59            android:layout_width="match_parent"
60            android:layout_height="wrap_content"
61            android:orientation="vertical"
62            app:layout_constraintStart_toStartOf="parent"
63            app:layout_constraintTop_toTopOf="parent"
64            app:layout_constraintEnd_toEndOf="parent"
65            app:layout_constraintBottom_toBottomOf="parent">
66            <TextView
67                android:id="@+id/label"
68                style="@style/LanguageCheckboxAndLabel"/>
69
70            <TextView
71                android:id="@+id/l10nWarn"
72                style="@style/LanguageCheckboxAndLabel"
73                android:textAppearance="?android:attr/textAppearanceListItemSecondary"
74                android:textColor="?android:textColorSecondary"
75                android:layout_marginTop="4dp"
76                android:text="@string/locale_not_translated"/>
77
78            <TextView
79                android:id="@+id/default_locale"
80                style="@style/LanguageCheckboxAndLabel"
81                android:textAppearance="?android:attr/textAppearanceListItemSecondary"
82                android:textColor="?android:textColorSecondary"
83                android:layout_marginTop="4dp"
84                android:text="@string/desc_current_default_language"/>
85
86        </LinearLayout>
87    </androidx.constraintlayout.widget.ConstraintLayout>
88
89    <ImageView
90        android:id="@+id/dragHandle"
91        android:layout_width="wrap_content"
92        android:layout_height="match_parent"
93        android:paddingStart="?android:attr/listPreferredItemPaddingStart"
94        android:paddingEnd="?android:attr/listPreferredItemPaddingEnd"
95        android:src="@drawable/drag_handle"
96        android:importantForAccessibility="no"
97        android:layout_alignParentEnd="true"
98        android:layout_centerVertical="true"/>
99
100</com.android.settings.localepicker.LocaleDragCell>