summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--java/com/android/dialer/theme/base/Theme.java3
-rw-r--r--java/com/android/dialer/theme/base/impl/AospThemeImpl.java17
-rw-r--r--java/com/android/dialer/theme/base/res/values/theme_dialer_dark.xml8
-rw-r--r--java/com/android/dialer/theme/base/res/values/theme_dialer_light.xml5
-rw-r--r--java/com/android/dialer/theme/common/res/drawable/bottom_sheet_background.xml23
-rw-r--r--java/com/android/dialer/theme/common/res/values/styles.xml9
-rw-r--r--java/com/android/incallui/answer/impl/SmsBottomSheetFragment.java13
7 files changed, 7 insertions, 71 deletions
diff --git a/java/com/android/dialer/theme/base/Theme.java b/java/com/android/dialer/theme/base/Theme.java
index 3356a018c..2a9975b4b 100644
--- a/java/com/android/dialer/theme/base/Theme.java
+++ b/java/com/android/dialer/theme/base/Theme.java
@@ -44,9 +44,6 @@ public interface Theme {
@StyleRes
int getApplicationThemeRes();
- @StyleRes
- int getBottomSheetStyleRes();
-
Context getThemedContext(Context context);
LayoutInflater getThemedLayoutInflator(LayoutInflater inflater);
diff --git a/java/com/android/dialer/theme/base/impl/AospThemeImpl.java b/java/com/android/dialer/theme/base/impl/AospThemeImpl.java
index cd1e16684..35dcef27c 100644
--- a/java/com/android/dialer/theme/base/impl/AospThemeImpl.java
+++ b/java/com/android/dialer/theme/base/impl/AospThemeImpl.java
@@ -102,25 +102,10 @@ public class AospThemeImpl implements Theme {
@Override
public @StyleRes int getApplicationThemeRes() {
switch (getTheme()) {
- case LIGHT:
- case LIGHT_M2:
- return R.style.Dialer_ThemeBase_NoActionBar;
case DARK:
return R.style.Dialer_Dark_ThemeBase_NoActionBar;
- case UNKNOWN:
- default:
- throw Assert.createIllegalStateFailException("Theme hasn't been set yet.");
- }
- }
-
- @Override
- public @StyleRes int getBottomSheetStyleRes() {
- switch (getTheme()) {
case LIGHT:
- case LIGHT_M2:
- return R.style.DialerBottomSheetDialogStyle_Light;
- case DARK:
- return R.style.DialerBottomSheetDialogStyle_Dark;
+ return R.style.Dialer_ThemeBase_NoActionBar;
case UNKNOWN:
default:
throw Assert.createIllegalStateFailException("Theme hasn't been set yet.");
diff --git a/java/com/android/dialer/theme/base/res/values/theme_dialer_dark.xml b/java/com/android/dialer/theme/base/res/values/theme_dialer_dark.xml
index 282ddfebb..d2cc0fc9c 100644
--- a/java/com/android/dialer/theme/base/res/values/theme_dialer_dark.xml
+++ b/java/com/android/dialer/theme/base/res/values/theme_dialer_dark.xml
@@ -64,10 +64,4 @@
<item name="colorIconOnUnthemedDarkBackground">@android:color/white</item>
<item name="colorPrimary20pct">@color/dialer_dark_theme_color_20pct</item>
</style>
-
- <style name="DialerBottomSheetDialogStyle.Dark">
- <item name="android:textColorPrimary">@color/dialer_dark_primary_text_color</item>
- <item name="android:colorBackgroundFloating">@color/google_grey_800</item>
- </style>
-
-</resources>
+</resources> \ No newline at end of file
diff --git a/java/com/android/dialer/theme/base/res/values/theme_dialer_light.xml b/java/com/android/dialer/theme/base/res/values/theme_dialer_light.xml
index b0428ee46..69ecba41e 100644
--- a/java/com/android/dialer/theme/base/res/values/theme_dialer_light.xml
+++ b/java/com/android/dialer/theme/base/res/values/theme_dialer_light.xml
@@ -84,11 +84,6 @@
<item name="android:windowAnimationStyle">@android:style/Animation</item>
</style>
- <style name="DialerBottomSheetDialogStyle.Light">
- <item name="android:textColorPrimary">@color/dialer_primary_text_color</item>
- <item name="android:colorBackgroundFloating">@android:color/white</item>
- </style>
-
<!-- Deprecated: Use Toolbar instead of ActionBar. -->
<!-- Used to style all Dialer's action bars. Every actionbar is awarded this for free if the parent
activity's theme extends from Dialer.ThemeBase.ActionBar or doesn't specify a theme. -->
diff --git a/java/com/android/dialer/theme/common/res/drawable/bottom_sheet_background.xml b/java/com/android/dialer/theme/common/res/drawable/bottom_sheet_background.xml
deleted file mode 100644
index 558277d42..000000000
--- a/java/com/android/dialer/theme/common/res/drawable/bottom_sheet_background.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
- ~ Copyright (C) 2018 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
- -->
-<shape xmlns:android="http://schemas.android.com/apk/res/android"
- android:shape="rectangle">
- <corners
- android:topLeftRadius="8dp"
- android:topRightRadius="8dp"/>
- <solid android:color="?android:attr/colorBackgroundFloating"/>
-</shape> \ No newline at end of file
diff --git a/java/com/android/dialer/theme/common/res/values/styles.xml b/java/com/android/dialer/theme/common/res/values/styles.xml
index ac23bdf98..2c6446ca1 100644
--- a/java/com/android/dialer/theme/common/res/values/styles.xml
+++ b/java/com/android/dialer/theme/common/res/values/styles.xml
@@ -31,13 +31,4 @@
<item name="android:layout_marginStart">20dp</item>
<item name="android:paddingLeft">12dp</item>
</style>
-
- <style name="DialerBottomSheetDialogStyle" parent="Theme.Design.BottomSheetDialog">
- <item name="android:windowBackground">@android:color/transparent</item>
- <item name="bottomSheetStyle">@style/BottomSheetStyle</item>
- </style>
-
- <style name="BottomSheetStyle" parent="Widget.Design.BottomSheet.Modal">
- <item name="android:background">@drawable/bottom_sheet_background</item>
- </style>
</resources> \ No newline at end of file
diff --git a/java/com/android/incallui/answer/impl/SmsBottomSheetFragment.java b/java/com/android/incallui/answer/impl/SmsBottomSheetFragment.java
index b06a0c681..6742e4a36 100644
--- a/java/com/android/incallui/answer/impl/SmsBottomSheetFragment.java
+++ b/java/com/android/incallui/answer/impl/SmsBottomSheetFragment.java
@@ -36,7 +36,6 @@ import android.widget.TextView;
import com.android.dialer.common.DpUtil;
import com.android.dialer.common.FragmentUtils;
import com.android.dialer.common.LogUtil;
-import com.android.dialer.theme.base.ThemeComponent;
import com.android.incallui.incalluilock.InCallUiLock;
import java.util.ArrayList;
import java.util.List;
@@ -69,8 +68,6 @@ public class SmsBottomSheetFragment extends BottomSheetDialogFragment {
}
}
layout.addView(newTextViewItem(null));
- int paddingVertical = (int) DpUtil.dpToPx(getContext(), 8);
- layout.setPadding(0, paddingVertical, 0, paddingVertical);
layout.setLayoutParams(new LayoutParams(LayoutParams.MATCH_PARENT, LayoutParams.WRAP_CONTENT));
return layout;
}
@@ -103,11 +100,11 @@ public class SmsBottomSheetFragment extends BottomSheetDialogFragment {
TextView textView = new TextView(context);
textView.setText(text == null ? getString(R.string.call_incoming_message_custom) : text);
- int paddingHorizontal = (int) DpUtil.dpToPx(context, 24);
- int paddingVertical = (int) DpUtil.dpToPx(context, 12);
- textView.setPadding(paddingHorizontal, paddingVertical, paddingHorizontal, paddingVertical);
+ int padding = (int) DpUtil.dpToPx(context, 16);
+ textView.setPadding(padding, padding, padding, padding);
textView.setBackground(background);
- textView.setTextAppearance(R.style.Dialer_TextAppearance_Primary2);
+ textView.setTextColor(context.getColor(R.color.blue_grey_100));
+ textView.setTextAppearance(R.style.TextAppearance_AppCompat_Widget_PopupMenu_Large);
LayoutParams params =
new LinearLayout.LayoutParams(LayoutParams.MATCH_PARENT, LayoutParams.WRAP_CONTENT);
@@ -127,7 +124,7 @@ public class SmsBottomSheetFragment extends BottomSheetDialogFragment {
@Override
public int getTheme() {
- return ThemeComponent.get(getContext()).theme().getBottomSheetStyleRes();
+ return R.style.Theme_Design_Light_BottomSheetDialog;
}
@Override