diff options
| author | Pranav Vashi <neobuddy89@gmail.com> | 2022-08-07 14:35:35 +0530 |
|---|---|---|
| committer | Semavi Ulusoy <doc.divxm@gmail.com> | 2022-09-13 10:47:56 +0300 |
| commit | de2ab12894bc620446458ad1602dfe5a4d45e874 (patch) | |
| tree | 0fe0cf1f1cb3569c80f4a79011a347bbd37097bf | |
| parent | 637bbc60ece7dd56071592dec91e648cd37e45c7 (diff) | |
Dialer: Use Material You theming for incallui dialpad
* Follow main dialpad in most aspects.
Signed-off-by: Pranav Vashi <neobuddy89@gmail.com>
Change-Id: I1c2e8c9349a39271bc2bbaa8c362cc1b0e2e346e
| -rw-r--r-- | java/com/android/incallui/DialpadFragment.java | 19 | ||||
| -rw-r--r-- | java/com/android/incallui/theme/res/values/colors.xml | 2 | ||||
| -rw-r--r-- | java/com/android/incallui/theme/res/values/styles.xml | 6 |
3 files changed, 0 insertions, 27 deletions
diff --git a/java/com/android/incallui/DialpadFragment.java b/java/com/android/incallui/DialpadFragment.java index 2ae2aca94..0f8e0c738 100644 --- a/java/com/android/incallui/DialpadFragment.java +++ b/java/com/android/incallui/DialpadFragment.java @@ -84,7 +84,6 @@ public class DialpadFragment extends BaseFragment<DialpadPresenter, DialpadUi> // KeyListener used with the "dialpad digits" EditText widget. private DtmfKeyListener dtmfKeyListener; private DialpadView dialpadView; - private int currentTextColor; private View endCallSpace; private boolean shouldShowEndCallSpace = true; @@ -142,7 +141,6 @@ public class DialpadFragment extends BaseFragment<DialpadPresenter, DialpadUi> final View parent = layoutInflater.inflate(R.layout.incall_dialpad_fragment, container, false); dialpadView = (DialpadView) parent.findViewById(R.id.dialpad_view); dialpadView.setCanDigitsBeEdited(false); - dialpadView.setBackgroundResource(R.color.incall_dialpad_background); dtmfDialerField = (EditText) parent.findViewById(R.id.digits); if (dtmfDialerField != null) { LogUtil.i("DialpadFragment.onCreateView", "creating dtmfKeyListener"); @@ -165,26 +163,9 @@ public class DialpadFragment extends BaseFragment<DialpadPresenter, DialpadUi> @Override public void onResume() { super.onResume(); - updateColors(); endCallSpace.setVisibility(shouldShowEndCallSpace ? View.VISIBLE : View.GONE); } - public void updateColors() { - int textColor = InCallPresenter.getInstance().getThemeColorManager().getPrimaryColor(); - - if (currentTextColor == textColor) { - return; - } - - DialpadKeyButton dialpadKey; - for (int i = 0; i < buttonIds.length; i++) { - dialpadKey = (DialpadKeyButton) dialpadView.findViewById(buttonIds[i]); - ((TextView) dialpadKey.findViewById(R.id.dialpad_key_number)).setTextColor(textColor); - } - - currentTextColor = textColor; - } - @Override public void onDestroyView() { dtmfKeyListener = null; diff --git a/java/com/android/incallui/theme/res/values/colors.xml b/java/com/android/incallui/theme/res/values/colors.xml index d05df686e..0ed34ff70 100644 --- a/java/com/android/incallui/theme/res/values/colors.xml +++ b/java/com/android/incallui/theme/res/values/colors.xml @@ -20,8 +20,6 @@ <!-- Used with some smaller texts in manage conference screen. --> <color name="conference_call_manager_secondary_text_color">#999999</color> - <color name="incall_dialpad_background">#ffffff</color> - <!-- Background color for status bar. For portrait this will be ignored. --> <color name="statusbar_background_color">?android:attr/colorPrimary</color> diff --git a/java/com/android/incallui/theme/res/values/styles.xml b/java/com/android/incallui/theme/res/values/styles.xml index 0c2cdc945..3eac4ba69 100644 --- a/java/com/android/incallui/theme/res/values/styles.xml +++ b/java/com/android/incallui/theme/res/values/styles.xml @@ -24,11 +24,8 @@ <item name="android:statusBarColor">@android:color/transparent</item> <item name="android:navigationBarColor">@android:color/transparent</item> <item name="android:windowDrawsSystemBarBackgrounds">true</item> - - <item name="dialpad_key_button_touch_tint">?attr/colorPrimary20pct</item> <item name="dialpad_style">@style/InCallDialpad</item> <item name="android:windowAnimationStyle">@null</item> - <item name="android:windowBackground">@drawable/incall_background_gradient</item> <item name="android:windowShowWallpaper">true</item> </style> @@ -41,11 +38,8 @@ <item name="android:windowDrawsSystemBarBackgrounds">true</item> <item name="android:colorPrimaryDark">@color/dialer_theme_color_dark</item> <item name="colorPrimaryDark">@color/dialer_theme_color_dark</item> - - <item name="dialpad_key_button_touch_tint">?attr/colorPrimary20pct</item> <item name="dialpad_style">@style/InCallDialpad</item> <item name="android:windowAnimationStyle">@null</item> - <item name="android:windowBackground">@drawable/incall_background_gradient</item> <item name="android:windowShowWallpaper">true</item> <item name="android:windowTranslucentStatus">true</item> |
