diff options
Diffstat (limited to 'java/com/android/incallui/incall')
5 files changed, 100 insertions, 73 deletions
diff --git a/java/com/android/incallui/incall/impl/InCallFragment.java b/java/com/android/incallui/incall/impl/InCallFragment.java index f0504bc56..e96060c06 100644 --- a/java/com/android/incallui/incall/impl/InCallFragment.java +++ b/java/com/android/incallui/incall/impl/InCallFragment.java @@ -45,6 +45,7 @@ import com.android.dialer.logging.DialerImpression; import com.android.dialer.logging.Logger; import com.android.dialer.multimedia.MultimediaData; import com.android.dialer.strictmode.StrictModeUtils; +import com.android.dialer.util.ViewUtil; import com.android.dialer.widget.LockableViewPager; import com.android.incallui.audioroute.AudioRouteSelectorDialogFragment; import com.android.incallui.audioroute.AudioRouteSelectorDialogFragment.AudioRouteSelectorPresenter; @@ -174,6 +175,9 @@ public class InCallFragment extends Fragment : TelephonyManager.NETWORK_TYPE_UNKNOWN; } phoneType = getContext().getSystemService(TelephonyManager.class).getPhoneType(); + View space = view.findViewById(R.id.navigation_bar_background); + space.getLayoutParams().height = ViewUtil.getNavigationBarHeight(getContext()); + return view; } diff --git a/java/com/android/incallui/incall/impl/res/color/incall_button_icon.xml b/java/com/android/incallui/incall/impl/res/color/incall_button_icon.xml index 6d8556759..8e9120b09 100644 --- a/java/com/android/incallui/incall/impl/res/color/incall_button_icon.xml +++ b/java/com/android/incallui/incall/impl/res/color/incall_button_icon.xml @@ -1,5 +1,21 @@ <?xml version="1.0" encoding="utf-8"?> +<!-- + ~ Copyright (C) 2017 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 + --> + <selector xmlns:android="http://schemas.android.com/apk/res/android"> - <item android:color="#FF01579B" android:state_checked="true"/> + <item android:color="#FF1C3AA9" android:state_checked="true"/> <item android:color="#FFFFFFFF"/> </selector> diff --git a/java/com/android/incallui/incall/impl/res/layout/frag_incall_voice.xml b/java/com/android/incallui/incall/impl/res/layout/frag_incall_voice.xml index c06f7099c..73b9c267e 100644 --- a/java/com/android/incallui/incall/impl/res/layout/frag_incall_voice.xml +++ b/java/com/android/incallui/incall/impl/res/layout/frag_incall_voice.xml @@ -15,107 +15,114 @@ ~ limitations under the License --> <FrameLayout - xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:app="http://schemas.android.com/apk/res-auto" - xmlns:tools="http://schemas.android.com/tools" - android:layout_width="match_parent" - android:layout_height="match_parent"> - - <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" - android:layout_height="match_parent" - android:clipChildren="false" - android:clipToPadding="false" - android:fitsSystemWindows="true"> + android:layout_height="match_parent"> - <LinearLayout - android:id="@id/incall_contact_grid" + <RelativeLayout + xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" + xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_marginTop="12dp" - android:layout_marginStart="@dimen/incall_window_margin_horizontal" - android:layout_marginEnd="@dimen/incall_window_margin_horizontal" - android:gravity="center_horizontal" - android:orientation="vertical"> + android:layout_height="match_parent" + android:clipChildren="false" + android:clipToPadding="false" + android:fitsSystemWindows="true"> + + <LinearLayout + android:id="@id/incall_contact_grid" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_marginTop="12dp" + android:layout_marginStart="@dimen/incall_window_margin_horizontal" + android:layout_marginEnd="@dimen/incall_window_margin_horizontal" + android:gravity="center_horizontal" + android:orientation="vertical"> <ImageView - android:id="@id/contactgrid_avatar" - android:layout_width="@dimen/incall_avatar_size" - android:layout_height="@dimen/incall_avatar_size" - android:layout_marginBottom="8dp" - android:elevation="2dp"/> + android:id="@id/contactgrid_avatar" + android:layout_width="@dimen/incall_avatar_size" + android:layout_height="@dimen/incall_avatar_size" + android:layout_marginBottom="8dp" + android:elevation="2dp"/> <include - layout="@layout/incall_contactgrid_top_row" - android:layout_width="wrap_content" - android:layout_height="wrap_content"/> + layout="@layout/incall_contactgrid_top_row" + android:layout_width="wrap_content" + android:layout_height="wrap_content"/> <!-- We have to keep deprecated singleLine to allow long text being truncated with ellipses. - b/31396406 --> + a bug --> <com.android.incallui.autoresizetext.AutoResizeTextView - android:id="@id/contactgrid_contact_name" - android:layout_width="wrap_content" - android:layout_height="wrap_content" - android:layout_marginBottom="4dp" - android:singleLine="true" - android:textAppearance="@style/Dialer.Incall.TextAppearance.Large" - app:autoResizeText_minTextSize="28sp" - tools:text="Jake Peralta" - tools:ignore="Deprecated"/> + android:id="@id/contactgrid_contact_name" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_marginBottom="4dp" + android:singleLine="true" + android:textAppearance="@style/Dialer.Incall.TextAppearance.Large" + app:autoResizeText_minTextSize="28sp" + tools:ignore="Deprecated" + tools:text="Jake Peralta"/> <include - layout="@layout/incall_contactgrid_bottom_row" - android:layout_width="wrap_content" - android:layout_height="wrap_content"/> + layout="@layout/incall_contactgrid_bottom_row" + android:layout_width="wrap_content" + android:layout_height="wrap_content"/> <FrameLayout - android:id="@+id/incall_location_holder" - android:layout_width="match_parent" - android:layout_height="match_parent"/> + android:id="@+id/incall_location_holder" + android:layout_width="match_parent" + android:layout_height="match_parent"/> </LinearLayout> <com.android.dialer.widget.LockableViewPager - android:id="@+id/incall_pager" - android:layout_width="match_parent" - android:layout_height="match_parent" - android:layout_above="@+id/incall_paginator" - android:layout_below="@+id/incall_contact_grid" - android:layout_centerHorizontal="true"/> + android:id="@+id/incall_pager" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:layout_above="@+id/incall_paginator" + android:layout_below="@+id/incall_contact_grid" + android:layout_centerHorizontal="true"/> <com.android.incallui.incall.impl.InCallPaginator android:id="@+id/incall_paginator" - android:layout_height="@dimen/paginator_height" android:layout_width="@dimen/paginator_width" + android:layout_height="@dimen/paginator_height" android:layout_above="@+id/incall_end_call" android:layout_centerHorizontal="true" android:visibility="gone"/> <FrameLayout - android:id="@+id/incall_dialpad_container" - style="@style/DialpadContainer" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_alignParentBottom="true" - android:clipChildren="false" - android:clipToPadding="false" - tools:background="@android:color/white" - tools:visibility="gone"/> + android:id="@+id/incall_dialpad_container" + style="@style/DialpadContainer" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_alignParentBottom="true" + android:clipChildren="false" + android:clipToPadding="false" + tools:background="@android:color/white" + tools:visibility="gone"/> <ImageButton - android:id="@+id/incall_end_call" - style="@style/Incall.Button.End" - android:layout_marginTop="16dp" - android:layout_marginBottom="36dp" - android:layout_alignParentBottom="true" - android:layout_centerHorizontal="true" - android:contentDescription="@string/incall_content_description_end_call"/> + android:id="@+id/incall_end_call" + style="@style/Incall.Button.End" + android:layout_marginTop="16dp" + android:layout_marginBottom="36dp" + android:layout_alignParentBottom="true" + android:layout_centerHorizontal="true" + android:contentDescription="@string/incall_content_description_end_call"/> </RelativeLayout> <FrameLayout - android:id="@id/incall_on_hold_banner" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_gravity="top"/> + android:id="@id/incall_on_hold_banner" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_gravity="top"/> + <FrameLayout + android:id="@+id/navigation_bar_background" + android:layout_width="match_parent" + android:layout_height="0dp" + android:layout_gravity="bottom" + android:visibility="gone" + android:background="@android:color/background_dark"/> </FrameLayout> diff --git a/java/com/android/incallui/incall/protocol/PrimaryCallState.java b/java/com/android/incallui/incall/protocol/PrimaryCallState.java index 4a50fbeaf..7a3abedcd 100644 --- a/java/com/android/incallui/incall/protocol/PrimaryCallState.java +++ b/java/com/android/incallui/incall/protocol/PrimaryCallState.java @@ -71,7 +71,7 @@ public class PrimaryCallState { @Nullable public final String customLabel; @Nullable public final TransformationInfo assistedDialingExtras; - // TODO: Convert to autovalue. b/34502119 + // TODO: Convert to autovalue. a bug public static PrimaryCallState createEmptyPrimaryCallState() { return createEmptyPrimaryCallStateWithState(DialerCall.State.IDLE, null); } diff --git a/java/com/android/incallui/incall/protocol/PrimaryInfo.java b/java/com/android/incallui/incall/protocol/PrimaryInfo.java index 69eee20ff..f7457c3ff 100644 --- a/java/com/android/incallui/incall/protocol/PrimaryInfo.java +++ b/java/com/android/incallui/incall/protocol/PrimaryInfo.java @@ -45,7 +45,7 @@ public class PrimaryInfo { public final boolean showInCallButtonGrid; public final int numberPresentation; - // TODO: Convert to autovalue. b/34502119 + // TODO: Convert to autovalue. a bug public static PrimaryInfo createEmptyPrimaryInfo() { return new PrimaryInfo( null, |