aboutsummaryrefslogtreecommitdiffstats
path: root/java/src/com/android/inputmethod/latin/LatinIME.java
diff options
context:
space:
mode:
authorKurt Partridge <kep@google.com>2013-03-20 11:28:31 -0700
committerKurt Partridge <kep@google.com>2013-03-25 17:31:25 -0700
commit87bc3a4a62b28f9c64ced813a9af531a563b6cd9 (patch)
treee2a0ef0af746aa7e9396e6f5f10ab4f3d5723ce3 /java/src/com/android/inputmethod/latin/LatinIME.java
parentfb658d6c531de8cfd55e4d36bffc9ccabc401f94 (diff)
downloadlatinime-87bc3a4a62b28f9c64ced813a9af531a563b6cd9.tar.gz
latinime-87bc3a4a62b28f9c64ced813a9af531a563b6cd9.tar.xz
latinime-87bc3a4a62b28f9c64ced813a9af531a563b6cd9.zip
Close ResearchLogger upon onFinishInputView
Previously, ResearchLogger#stop() was called both in LatinIME#onFinishInputView() and in LatinIME#onWindowHidden(). This resulted in multiple logs being written. Since onFinishInputView is the more reliable of the two (it is called in InputMethodService#onDestroy; onWindowHidden is not), the code now uses onFinishInputView as a stopping signal. Change-Id: Iae4b8c3bdab226027624eeab19b3737367e4a108
Diffstat (limited to 'java/src/com/android/inputmethod/latin/LatinIME.java')
-rw-r--r--java/src/com/android/inputmethod/latin/LatinIME.java8
1 files changed, 3 insertions, 5 deletions
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java
index ea7ee6d5b..e66bcae1f 100644
--- a/java/src/com/android/inputmethod/latin/LatinIME.java
+++ b/java/src/com/android/inputmethod/latin/LatinIME.java
@@ -803,10 +803,6 @@ public final class LatinIME extends InputMethodService implements KeyboardAction
@Override
public void onWindowHidden() {
- if (ProductionFlag.USES_DEVELOPMENT_ONLY_DIAGNOSTICS) {
- ResearchLogger.latinIME_onWindowHidden(mLastSelectionStart, mLastSelectionEnd,
- getCurrentInputConnection());
- }
super.onWindowHidden();
final MainKeyboardView mainKeyboardView = mKeyboardSwitcher.getMainKeyboardView();
if (mainKeyboardView != null) {
@@ -834,8 +830,10 @@ public final class LatinIME extends InputMethodService implements KeyboardAction
// Remove pending messages related to update suggestions
mHandler.cancelUpdateSuggestionStrip();
resetComposingState(true /* alsoResetLastComposedWord */);
+ // Notify ResearchLogger
if (ProductionFlag.USES_DEVELOPMENT_ONLY_DIAGNOSTICS) {
- ResearchLogger.getInstance().latinIME_onFinishInputViewInternal();
+ ResearchLogger.latinIME_onFinishInputViewInternal(finishingInput, mLastSelectionStart,
+ mLastSelectionEnd, getCurrentInputConnection());
}
}