From 99bd42b29504ee214f72343cceeab06d2999eaf6 Mon Sep 17 00:00:00 2001 From: Kurt Partridge Date: Fri, 21 Dec 2012 12:22:06 -0800 Subject: [PATCH] [Rlog24z] Initialize statistics variables Change-Id: I73a6009294a4f559a93b6ea9ceb4ea2683d97486 --- .../inputmethod/research/ResearchLogger.java | 4 ++-- .../android/inputmethod/research/Statistics.java | 14 +++++++++----- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/java/src/com/android/inputmethod/research/ResearchLogger.java b/java/src/com/android/inputmethod/research/ResearchLogger.java index 53f321fed..035e7e08a 100644 --- a/java/src/com/android/inputmethod/research/ResearchLogger.java +++ b/java/src/com/android/inputmethod/research/ResearchLogger.java @@ -1451,8 +1451,8 @@ public class ResearchLogger implements SharedPreferences.OnSharedPreferenceChang statistics.mDuringRepeatedDeleteKeysCounter.getAverageTime(), statistics.mAfterDeleteKeyCounter.getAverageTime(), statistics.mDictionaryWordCount, statistics.mSplitWordsCount, - statistics.mGestureInputCount, - statistics.mGestureCharsCount, + statistics.mGesturesInputCount, + statistics.mGesturesCharsCount, statistics.mGesturesDeletedCount); } } diff --git a/java/src/com/android/inputmethod/research/Statistics.java b/java/src/com/android/inputmethod/research/Statistics.java index f9c072967..a02aabf3c 100644 --- a/java/src/com/android/inputmethod/research/Statistics.java +++ b/java/src/com/android/inputmethod/research/Statistics.java @@ -42,11 +42,11 @@ public class Statistics { // Number of words split and spaces automatically entered. int mSplitWordsCount; // Number of gestures that were input. - int mGestureInputCount; + int mGesturesInputCount; // Number of gestures that were deleted. int mGesturesDeletedCount; // Total number of characters in words entered by gesture. - int mGestureCharsCount; + int mGesturesCharsCount; // Whether the text field was empty upon editing boolean mIsEmptyUponStarting; boolean mIsEmptinessStateKnown; @@ -107,13 +107,17 @@ public class Statistics { mSpaceCount = 0; mDeleteKeyCount = 0; mWordCount = 0; + mDictionaryWordCount = 0; + mSplitWordsCount = 0; + mGesturesInputCount = 0; + mGesturesDeletedCount = 0; mIsEmptyUponStarting = true; mIsEmptinessStateKnown = false; mKeyCounter.reset(); mBeforeDeleteKeyCounter.reset(); mDuringRepeatedDeleteKeysCounter.reset(); mAfterDeleteKeyCounter.reset(); - mGestureCharsCount = 0; + mGesturesCharsCount = 0; mGesturesDeletedCount = 0; mLastTapTime = 0; @@ -168,8 +172,8 @@ public class Statistics { } public void recordGestureInput(final int numCharsEntered) { - mGestureInputCount++; - mGestureCharsCount += numCharsEntered; + mGesturesInputCount++; + mGesturesCharsCount += numCharsEntered; } public void setIsEmptyUponStarting(final boolean isEmpty) {