• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (C) 2015 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<!-- In (hopefully very rare) case dialog is too high: allow scrolling -->
18<ScrollView
19    xmlns:android="http://schemas.android.com/apk/res/android"
20    android:layout_width="match_parent"
21    android:layout_height="match_parent"
22    style="@style/PermissionGrantScrollView">
23
24    <LinearLayout
25        style="@style/PermissionGrantSingleton">
26
27        <!-- The dialog -->
28        <LinearLayout
29            android:theme="@style/Theme.PermissionGrantDialog"
30            style="@style/PermissionGrantDialog">
31
32            <LinearLayout
33                android:id="@+id/content_container"
34                style="@style/PermissionGrantContent">
35
36                <LinearLayout
37                    style="@style/PermissionGrantDescription">
38
39                    <ImageView
40                        android:id="@+id/permission_icon"
41                        style="@style/PermissionGrantTitleIcon" />
42
43                    <TextView
44                        android:id="@+id/permission_message"
45                        style="@style/PermissionGrantTitleMessage" />
46
47                </LinearLayout>
48
49                <TextView
50                    android:id="@+id/detail_message"
51                    style="@style/PermissionGrantDetailMessage" />
52
53            </LinearLayout>
54
55            <!-- Buttons on bottom of dialog -->
56            <LinearLayout
57                style="@style/PermissionGrantButtonList">
58
59                <Space
60                    style="@style/PermissionGrantButtonBarSpace"/>
61
62                <Button
63                    android:id="@+id/permission_allow_button"
64                    android:text="@string/grant_dialog_button_allow"
65                    style="@style/PermissionGrantButtonAllow" />
66
67                <Button
68                    android:id="@+id/permission_allow_always_button"
69                    android:text="@string/grant_dialog_button_allow_always"
70                    style="@style/PermissionGrantButtonAllowAlways" />
71
72                <Button
73                    android:id="@+id/permission_allow_foreground_only_button"
74                    android:text="@string/grant_dialog_button_allow_foreground"
75                    style="@style/PermissionGrantButtonAllowForeground" />
76
77                <Button
78                    android:id="@+id/permission_deny_button"
79                    android:text="@string/grant_dialog_button_deny"
80                    style="@style/PermissionGrantButtonDeny" />
81
82                <Button
83                    android:id="@+id/permission_deny_and_dont_ask_again_button"
84                    android:text="@string/grant_dialog_button_deny_and_dont_ask_again"
85                    style="@style/PermissionGrantButtonDenyDontAskAgain" />
86            </LinearLayout>
87
88        </LinearLayout>
89    </LinearLayout>
90</ScrollView>