diff --git a/java/src/com/android/inputmethod/keyboard/KeyboardView.java b/java/src/com/android/inputmethod/keyboard/KeyboardView.java
index 1e7a0618e221d703630a4b49df75f5426665d3dd..f8bce40b1ad60c861161241f83dbdeb7467e4928 100644
--- a/java/src/com/android/inputmethod/keyboard/KeyboardView.java
+++ b/java/src/com/android/inputmethod/keyboard/KeyboardView.java
@@ -121,7 +121,7 @@ public class KeyboardView extends View implements PointerTracker.UIProxy {
     private float mPreviewTextRatio;
     private int mPreviewTextSize;
     private boolean mShowKeyPreviewPopup = true;
-    private int mKeyPreviewPopupDisplayedY;
+    private int mKeyPreviewPopupDisplayedY = -1;
     private final int mDelayBeforePreview;
     private int mDelayAfterPreview;
     private ViewGroup mPreviewPlacer;