Merge "add productionFlag for checking split keyboard status"
diff --git a/java-overridable/src/com/android/inputmethod/latin/utils/StatsUtils.java b/java-overridable/src/com/android/inputmethod/latin/utils/StatsUtils.java
index 198afeb..38735ec 100644
--- a/java-overridable/src/com/android/inputmethod/latin/utils/StatsUtils.java
+++ b/java-overridable/src/com/android/inputmethod/latin/utils/StatsUtils.java
@@ -22,6 +22,10 @@
 
 public final class StatsUtils {
 
+    private StatsUtils() {
+        // Intentional empty constructor.
+    }
+
     public static void onCreate(final SettingsValues settingsValues,
             RichInputMethodManager richImm) {
     }
@@ -50,4 +54,13 @@
 
     public static void onRevertSwapPunctuation() {
     }
+
+    public static void onFinishInputView() {
+    }
+
+    public static void onCreateInputView() {
+    }
+
+    public static void onStartInputView(int inputType, int displayOrientation, boolean restarting) {
+    }
 }
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java
index d210499..a624343 100644
--- a/java/src/com/android/inputmethod/latin/LatinIME.java
+++ b/java/src/com/android/inputmethod/latin/LatinIME.java
@@ -740,6 +740,7 @@
 
     @Override
     public View onCreateInputView() {
+        StatsUtils.onCreateInputView();
         return mKeyboardSwitcher.onCreateInputView(mIsHardwareAcceleratedDrawingEnabled);
     }
 
@@ -772,6 +773,7 @@
 
     @Override
     public void onFinishInputView(final boolean finishingInput) {
+        StatsUtils.onFinishInputView();
         mHandler.onFinishInputView(finishingInput);
     }
 
@@ -849,6 +851,11 @@
 
         final boolean inputTypeChanged = !currentSettingsValues.isSameInputType(editorInfo);
         final boolean isDifferentTextField = !restarting || inputTypeChanged;
+
+        StatsUtils.onStartInputView(editorInfo.inputType,
+                Settings.getInstance().getCurrent().mDisplayOrientation,
+                !isDifferentTextField);
+
         if (isDifferentTextField) {
             mSubtypeSwitcher.updateParametersOnStartInputView();
         }