abouttreesummaryrefslogcommitdiff
path: root/srcs/juloo.keyboard2/EmojiKeyButton.java
diff options
context:
space:
mode:
authorJules Aguillon2021-04-18 23:28:49 +0200
committerJules Aguillon2021-04-18 23:28:49 +0200
commit81803c406a82862602aa5e350fcc07692e9f16a6 (patch)
tree55d0a58f6c37f0707d1d0988d1e937c514bbf3e2 /srcs/juloo.keyboard2/EmojiKeyButton.java
parent67d3a99a92a457e26a987bd722ce3b46e171b2b1 (diff)
downloadunexpected-keyboard-81803c406a82862602aa5e350fcc07692e9f16a6.tar.gz
unexpected-keyboard-81803c406a82862602aa5e350fcc07692e9f16a6.zip
Separate handling of modifiers from KeyValue class
KeyValue defines an ADT and some of its values, it now contains public final fields and no internal logic. KeyModifier handles modifiers and accents and creates new instances of KeyValue when needed. This operation is now properly cached.
Diffstat (limited to 'srcs/juloo.keyboard2/EmojiKeyButton.java')
-rw-r--r--srcs/juloo.keyboard2/EmojiKeyButton.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/srcs/juloo.keyboard2/EmojiKeyButton.java b/srcs/juloo.keyboard2/EmojiKeyButton.java
index 00a9a69..de9f206 100644
--- a/srcs/juloo.keyboard2/EmojiKeyButton.java
+++ b/srcs/juloo.keyboard2/EmojiKeyButton.java
@@ -15,8 +15,8 @@ public class EmojiKeyButton extends Button
super(context, attrs);
setOnClickListener(this);
_key = KeyValue.getKeyByName(attrs.getAttributeValue(null, "key"));
- setText(_key.getSymbol(0));
- if ((_key.getFlags() & KeyValue.FLAG_KEY_FONT) != 0)
+ setText(_key.symbol);
+ if ((_key.flags & KeyValue.FLAG_KEY_FONT) != 0)
setTypeface(((Keyboard2)context).getSpecialKeyFont());
}