You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

194 lines
8.8 KiB

<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2014 The Android Open Source Project
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<!-- Layout for the emergency dialer; see EmergencyDialer.java. -->
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent">
<!-- Emergency dialer shortcuts layout-->
<FrameLayout
android:id="@+id/emergency_dialer_shortcuts"
android:accessibilityPaneTitle="@string/emergencyDialerIconLabel"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="gone">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<include layout="@layout/emergency_information"/>
<include layout="@layout/emergency_shortcut_buttons_group"/>
</LinearLayout>
<FrameLayout
android:id="@+id/dialpad_button_container"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:layout_gravity="bottom|center"
android:layout_marginBottom="@dimen/emergency_dialer_dialpad_button_margin">
<ImageButton
android:id="@+id/floating_action_button_dialpad"
android:layout_width="@dimen/dialpad_button_width"
android:layout_height="@dimen/dialpad_button_height"
android:background="@drawable/floating_action_button_red"
android:contentDescription="@string/description_dialpad_button"
android:src="@drawable/ic_dialpad_white_24"
android:scaleType="centerInside"
android:backgroundTint="@color/emergency_dialpad_fab_tint_color"/>
</FrameLayout>
</FrameLayout>
<!--Emergency Dialer Layout-->
<FrameLayout
android:id="@+id/emergency_dialer"
android:accessibilityPaneTitle="@string/pane_title_emergency_dialpad"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:paddingBottom="@dimen/dialpad_bottom_padding"
android:visibility="visible">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="bottom"
android:orientation="vertical">
<!-- FrameLayout -->
<com.android.phone.EmergencyActionGroup
android:id="@+id/emergency_action_group"
android:layout_height="64dp"
android:layout_width="match_parent"
android:layout_marginHorizontal="36dp"
android:layout_marginTop="16dp"
android:layout_marginBottom="24dp">
<!-- Button that says: Emergency Information -->
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<Button android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:background="@drawable/btn_emergency"
android:id="@+id/action1" />
<Button android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:background="@drawable/btn_emergency"
android:id="@+id/action2" />
<Button android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:background="@drawable/btn_emergency"
android:id="@+id/action3" />
</LinearLayout>
<!-- View that shows up on top of "emergency information" button
and asks you to tap again to confirm the action -->
<FrameLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:id="@+id/selected_container"
android:visibility="invisible"
android:focusable="true"
android:clickable="true">
<View
android:layout_width="match_parent"
android:layout_height="match_parent"
android:backgroundTint="#ffe32926"
android:focusable="false"
android:clickable="false"
style="?android:attr/buttonStyle"/>
<View
android:layout_width="match_parent"
android:layout_height="match_parent"
android:id="@+id/ripple_view"
android:backgroundTint="#22ffffff"
android:visibility="invisible"
android:focusable="false"
android:clickable="false"
style="?android:attr/buttonStyle"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:focusable="false"
android:clickable="false"
android:backgroundTint="#00000000"
style="?android:attr/buttonStyle">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:maxLines="1"
android:id="@+id/selected_label"
android:textColor="@android:color/white"
android:textAppearance="?android:attr/textAppearanceButton" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:id="@+id/launch_hint"
android:maxLines="1"
android:autoSizeTextType="uniform"
android:text="@string/emergency_action_launch_hint"
android:textColor="@android:color/white"
android:textStyle="italic" />
</LinearLayout>
</FrameLayout>
</com.android.phone.EmergencyActionGroup>
<Space
android:id="@+id/emergency_info_dialpad_spacer"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"/>
<include layout="@layout/dialpad_view_unthemed"
android:layout_height="wrap_content"
android:layout_width="match_parent"
android:theme="?attr/dialpadTheme" />
</LinearLayout>
<Space
android:id="@+id/floating_action_button_margin_bottom"
android:layout_width="match_parent"
android:layout_height="@dimen/floating_action_button_margin_bottom"
android:layout_alignParentBottom="true"/>
<FrameLayout
android:id="@+id/floating_action_button_container"
android:layout_width="@dimen/floating_action_button_width"
android:layout_height="@dimen/floating_action_button_height"
android:layout_gravity="center_horizontal|bottom" >
<ImageButton
android:id="@+id/floating_action_button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:background="@drawable/floating_action_button"
android:contentDescription="@string/description_dial_button"
android:src="@drawable/fab_ic_call"/>
</FrameLayout>
</FrameLayout>
</FrameLayout>