]> gitweb.stoutner.com Git - PrivacyBrowserAndroid.git/blob - app/src/main/res/layout/simple_spinner_dropdown_item_huawei_fix.xml
Add attribution to Thomas Jensen <lianergoist@vongriffen.dk> for Huawei spinner fix.
[PrivacyBrowserAndroid.git] / app / src / main / res / layout / simple_spinner_dropdown_item_huawei_fix.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <!--
3     Modifications copyright © 2017 Soren Stoutner <soren@stoutner.com>.
4
5     `android:layout_height="wrap_content` fix contributed 2017 Thomas Jensen <lianergoist@vongriffen.dk>.  Copyright assigned to Soren Stoutner <soren@stoutner.com>.
6
7     `simple_spinner_dropdown_item_huawei_fix.xml` comes from the Android API 25 platform SDK, and is usually referenced as `android.R.layout.simple_spinner_dropdown_item`.
8
9     The licensing information for the original file is below:
10
11     //device/apps/common/assets/res/any/layout/simple_spinner_item.xml
12
13     Copyright 2008, The Android Open Source Project
14
15     Licensed under the Apache License, Version 2.0 (the "License")
16     you may not use this file except in compliance with the License.
17     You may obtain a copy of the License at
18
19         http://www.apache.org/licenses/LICENSE-2.0
20
21     Unless required by applicable law or agreed to in writing, software
22     distributed under the License is distributed on an “AS IS” BASIS,
23     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
24     See the License for the specific language governing permissions and
25     limitations under the License. -->
26
27 <!-- Huawei did something to their customizations to Android 7.0 (API 24) to break scrolling on `spinners`.  Modifying this file to set `android:layout_height="wrap_content"` resolves the issue. -->
28 <CheckedTextView
29     xmlns:android="http://schemas.android.com/apk/res/android"
30     android:id="@android:id/text1"
31     android:layout_height="wrap_content"
32     android:layout_width="match_parent"
33     style="?android:attr/spinnerDropDownItemStyle"
34     android:maxLines="1"
35     android:ellipsize="marquee" />