1<?xml version="1.0" encoding="utf-8"?> 2<!-- Copyright (C) 2014 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<!-- Layout for the emergency dialer; see EmergencyDialer.java. --> 18<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" 19 android:layout_width="match_parent" 20 android:layout_height="match_parent"> 21 22 <!-- Emergency dialer shortcuts layout--> 23 <FrameLayout 24 android:id="@+id/emergency_dialer_shortcuts" 25 android:accessibilityPaneTitle="@string/emergencyDialerIconLabel" 26 android:layout_width="match_parent" 27 android:layout_height="match_parent" 28 android:visibility="gone"> 29 <LinearLayout 30 android:layout_width="match_parent" 31 android:layout_height="match_parent" 32 android:orientation="vertical"> 33 <include layout="@layout/emergency_information"/> 34 <include layout="@layout/emergency_shortcut_buttons_group"/> 35 </LinearLayout> 36 37 <FrameLayout 38 android:id="@+id/dialpad_button_container" 39 android:layout_height="wrap_content" 40 android:layout_width="wrap_content" 41 android:layout_gravity="bottom|center" 42 android:layout_marginBottom="@dimen/emergency_dialer_dialpad_button_margin"> 43 <ImageButton 44 android:id="@+id/floating_action_button_dialpad" 45 android:layout_width="@dimen/dialpad_button_width" 46 android:layout_height="@dimen/dialpad_button_height" 47 android:background="@drawable/floating_action_button_red" 48 android:contentDescription="@string/description_dialpad_button" 49 android:src="@drawable/ic_dialpad_white_24" 50 android:scaleType="centerInside" 51 android:backgroundTint="@color/emergency_dialpad_fab_tint_color"/> 52 </FrameLayout> 53 </FrameLayout> 54 55 <!--Emergency Dialer Layout--> 56 <FrameLayout 57 android:id="@+id/emergency_dialer" 58 android:accessibilityPaneTitle="@string/pane_title_emergency_dialpad" 59 android:layout_width="match_parent" 60 android:layout_height="match_parent" 61 android:paddingBottom="@dimen/dialpad_bottom_padding" 62 android:visibility="visible"> 63 <LinearLayout 64 android:layout_width="match_parent" 65 android:layout_height="match_parent" 66 android:layout_gravity="bottom" 67 android:orientation="vertical"> 68 69 <!-- FrameLayout --> 70 <com.android.phone.EmergencyActionGroup 71 android:id="@+id/emergency_action_group" 72 android:layout_height="64dp" 73 android:layout_width="match_parent" 74 android:layout_marginHorizontal="36dp" 75 android:layout_marginTop="16dp" 76 android:layout_marginBottom="24dp"> 77 78 <!-- Button that says: Emergency Information --> 79 <LinearLayout 80 android:layout_width="match_parent" 81 android:layout_height="match_parent"> 82 <Button android:layout_width="0dp" 83 android:layout_height="match_parent" 84 android:layout_weight="1" 85 android:background="@drawable/btn_emergency" 86 android:id="@+id/action1" /> 87 <Button android:layout_width="0dp" 88 android:layout_height="match_parent" 89 android:layout_weight="1" 90 android:background="@drawable/btn_emergency" 91 android:id="@+id/action2" /> 92 <Button android:layout_width="0dp" 93 android:layout_height="match_parent" 94 android:layout_weight="1" 95 android:background="@drawable/btn_emergency" 96 android:id="@+id/action3" /> 97 </LinearLayout> 98 99 <!-- View that shows up on top of "emergency information" button 100 and asks you to tap again to confirm the action --> 101 <FrameLayout 102 android:layout_width="match_parent" 103 android:layout_height="match_parent" 104 android:id="@+id/selected_container" 105 android:visibility="invisible" 106 android:focusable="true" 107 android:clickable="true"> 108 109 <View 110 android:layout_width="match_parent" 111 android:layout_height="match_parent" 112 android:backgroundTint="#ffe32926" 113 android:focusable="false" 114 android:clickable="false" 115 style="?android:attr/buttonStyle"/> 116 117 <View 118 android:layout_width="match_parent" 119 android:layout_height="match_parent" 120 android:id="@+id/ripple_view" 121 android:backgroundTint="#22ffffff" 122 android:visibility="invisible" 123 android:focusable="false" 124 android:clickable="false" 125 style="?android:attr/buttonStyle"/> 126 127 <LinearLayout 128 android:layout_width="match_parent" 129 android:layout_height="match_parent" 130 android:orientation="vertical" 131 android:focusable="false" 132 android:clickable="false" 133 android:backgroundTint="#00000000" 134 style="?android:attr/buttonStyle"> 135 <TextView 136 android:layout_width="match_parent" 137 android:layout_height="wrap_content" 138 android:gravity="center" 139 android:maxLines="1" 140 android:id="@+id/selected_label" 141 android:textColor="@android:color/white" 142 android:textAppearance="?android:attr/textAppearanceButton" /> 143 <TextView 144 android:layout_width="wrap_content" 145 android:layout_height="wrap_content" 146 android:id="@+id/launch_hint" 147 android:maxLines="1" 148 android:autoSizeTextType="uniform" 149 android:text="@string/emergency_action_launch_hint" 150 android:textColor="@android:color/white" 151 android:textStyle="italic" /> 152 </LinearLayout> 153 154 </FrameLayout> 155 156 </com.android.phone.EmergencyActionGroup> 157 <Space 158 android:id="@+id/emergency_info_dialpad_spacer" 159 android:layout_width="match_parent" 160 android:layout_height="0dp" 161 android:layout_weight="1"/> 162 <include layout="@layout/dialpad_view_unthemed" 163 android:layout_height="wrap_content" 164 android:layout_width="match_parent" 165 android:theme="?attr/dialpadTheme" /> 166 167 </LinearLayout> 168 169 <Space 170 android:id="@+id/floating_action_button_margin_bottom" 171 android:layout_width="match_parent" 172 android:layout_height="@dimen/floating_action_button_margin_bottom" 173 android:layout_alignParentBottom="true"/> 174 175 <FrameLayout 176 android:id="@+id/floating_action_button_container" 177 android:layout_width="@dimen/floating_action_button_width" 178 android:layout_height="@dimen/floating_action_button_height" 179 android:layout_gravity="center_horizontal|bottom" > 180 181 <ImageButton 182 android:id="@+id/floating_action_button" 183 android:layout_width="wrap_content" 184 android:layout_height="wrap_content" 185 android:layout_gravity="center" 186 android:background="@drawable/floating_action_button" 187 android:contentDescription="@string/description_dial_button" 188 android:src="@drawable/fab_ic_call"/> 189 </FrameLayout> 190 191 </FrameLayout> 192 193</FrameLayout> 194