Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 53e621bb authored by Georg Veichtlbauer's avatar Georg Veichtlbauer Committed by Nolen Johnson
Browse files

LatinIME: Fix NPE when using a device with a physical keyboard

Change-Id: Id0e624c590166dd4537c5bec218b8acd4842fa64
parent a451d520
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -2031,6 +2031,10 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen

    /** @noinspection deprecation*/
    private void updateNavigationBarColor() {
        // This may happen for devices with a physical keyboard
        if (mInputView == null)
            return;

        if (BuildCompatUtils.EFFECTIVE_SDK_INT > Build.VERSION_CODES.R) {
            Drawable bg = mInputView.findViewById(R.id.keyboard_view).getBackground();
            Window w = getWindow().getWindow();