update readme, small adjustments

This commit is contained in:
Helium314 2023-09-04 10:21:08 +02:00
parent 454a54ada7
commit 42ee6639b0
3 changed files with 16 additions and 42 deletions

View file

@ -68,7 +68,6 @@ import static org.dslul.openboard.inputmethod.latin.common.Constants.NOT_A_COORD
* </ol>
* Because of the above reasons, this class doesn't extend {@link KeyboardView}.
*/
@SuppressWarnings("deprecation")
public final class EmojiPalettesView extends LinearLayout
implements OnTabChangeListener, View.OnClickListener, View.OnTouchListener,
OnKeyEventListener {
@ -174,6 +173,8 @@ public final class EmojiPalettesView extends LinearLayout
@Override
protected void onFinishInflate() {
super.onFinishInflate();
final Colors colors = Settings.getInstance().getCurrent().mColors;
mTabHost = findViewById(R.id.emoji_category_tabhost);
mTabHost.setup();
for (final EmojiCategory.CategoryProperties properties
@ -189,7 +190,6 @@ public final class EmojiPalettesView extends LinearLayout
tabWidget.setBackgroundResource(mCategoryIndicatorDrawableResId);
tabWidget.setLeftStripDrawable(mCategoryIndicatorBackgroundResId);
tabWidget.setRightStripDrawable(mCategoryIndicatorBackgroundResId);
final Colors colors = Settings.getInstance().getCurrent().mColors;
tabWidget.setBackgroundColor(colors.accent);
}
@ -272,7 +272,6 @@ public final class EmojiPalettesView extends LinearLayout
mEmojiLayoutParams.setKeyProperties(mSpacebar);
mSpacebarIcon = findViewById(R.id.emoji_keyboard_space_icon);
final Colors colors = Settings.getInstance().getCurrent().mColors;
colors.setBackgroundColor(mAlphabetKeyLeft.getBackground(), Colors.TYPE_FUNCTIONAL);
colors.setBackgroundColor(mDeleteKey.getBackground(), Colors.TYPE_FUNCTIONAL);
colors.setBackgroundColor(mSpacebar.getBackground(), Colors.TYPE_SPACE);

View file

@ -200,12 +200,12 @@ public class Colors {
@ColorInt
public static int brighten(@ColorInt final int color) {
return adjustLuminosityAndKeepAlpha(color, 0.05f);
return adjustLuminosityAndKeepAlpha(color, 0.06f);
}
@ColorInt
public static int darken(@ColorInt final int color) {
return adjustLuminosityAndKeepAlpha(color, -0.05f);
return adjustLuminosityAndKeepAlpha(color, -0.06f);
}
}