fix holo action key moreKeys

This commit is contained in:
Helium314 2023-09-04 08:35:12 +02:00
parent 395c4bac09
commit fe51ee5f98
2 changed files with 6 additions and 2 deletions

View file

@ -189,6 +189,9 @@ public class KeyboardView extends View {
} }
mColors.setBackgroundColor(mActionKeyBackground, Colors.TYPE_ACTION); mColors.setBackgroundColor(mActionKeyBackground, Colors.TYPE_ACTION);
mColors.setBackgroundColor(mSpacebarBackground, Colors.TYPE_SPACE); mColors.setBackgroundColor(mSpacebarBackground, Colors.TYPE_SPACE);
if (this instanceof MoreKeysKeyboardView)
mColors.setBackgroundColor(mFunctionalKeyBackground, Colors.TYPE_ADJUSTED_BACKGROUND);
else
mColors.setBackgroundColor(mFunctionalKeyBackground, Colors.TYPE_FUNCTIONAL); mColors.setBackgroundColor(mFunctionalKeyBackground, Colors.TYPE_FUNCTIONAL);
if (this.getClass() == MoreKeysKeyboardView.class) if (this.getClass() == MoreKeysKeyboardView.class)
getBackground().setColorFilter(mColors.adjustedBackgroundFilter); getBackground().setColorFilter(mColors.adjustedBackgroundFilter);
@ -620,7 +623,7 @@ public class KeyboardView extends View {
} }
private void setKeyIconColor(Key key, Drawable icon, Keyboard keyboard) { private void setKeyIconColor(Key key, Drawable icon, Keyboard keyboard) {
if (key.isAccentColored() && !(mColors instanceof HoloColors)) { // todo: again sth that should not be here if (key.isAccentColored() && !(mColors instanceof HoloColors)) { // todo: this logic should not be here
icon.setColorFilter(mColors.actionKeyIconColorFilter); icon.setColorFilter(mColors.actionKeyIconColorFilter);
} else if (key.isShift() && keyboard != null) { } else if (key.isShift() && keyboard != null) {
// todo (idea): replace shift icon with white one and use the normal multiply filters // todo (idea): replace shift icon with white one and use the normal multiply filters

View file

@ -122,6 +122,7 @@
> >
<item name="android:background">@drawable/keyboard_popup_panel_background_holo_white</item> <item name="android:background">@drawable/keyboard_popup_panel_background_holo_white</item>
<item name="keyBackground">@drawable/btn_keyboard_key_popup_holo_white</item> <item name="keyBackground">@drawable/btn_keyboard_key_popup_holo_white</item>
<item name="functionalKeyBackground">@drawable/btn_keyboard_key_popup_holo_white</item>
<item name="divider">@drawable/more_keys_divider</item> <item name="divider">@drawable/more_keys_divider</item>
<item name="keyTypeface">normal</item> <item name="keyTypeface">normal</item>
<item name="verticalCorrection">@dimen/config_more_keys_keyboard_vertical_correction_holo</item> <item name="verticalCorrection">@dimen/config_more_keys_keyboard_vertical_correction_holo</item>