abouttreesummaryrefslogcommitdiff
path: root/srcs/juloo.keyboard2
diff options
context:
space:
mode:
Diffstat (limited to 'srcs/juloo.keyboard2')
-rw-r--r--srcs/juloo.keyboard2/Keyboard2.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/srcs/juloo.keyboard2/Keyboard2.java b/srcs/juloo.keyboard2/Keyboard2.java
index 4886cc3..a68b954 100644
--- a/srcs/juloo.keyboard2/Keyboard2.java
+++ b/srcs/juloo.keyboard2/Keyboard2.java
@@ -157,6 +157,8 @@ public class Keyboard2 extends InputMethodService
// Android might return a random subtype, for example, the first in the
// list alphabetically.
InputMethodSubtype current_subtype = imm.getCurrentInputMethodSubtype();
+ if (current_subtype == null)
+ return null;
for (InputMethodSubtype s : enabled_subtypes)
if (s.getLanguageTag().equals(current_subtype.getLanguageTag()))
return s;