Add logging

- add logging for delete
- add logging for inputchar

Change-Id: I684692385f4c3acb66ab2bcd6421dae1d84feb8f
main
satok 2010-04-28 16:43:41 +09:00
parent 8677ac3586
commit 22f7ea7518
2 changed files with 5 additions and 0 deletions

View File

@ -937,6 +937,7 @@ public class LatinIME extends InputMethodService
case Keyboard.KEYCODE_DELETE: case Keyboard.KEYCODE_DELETE:
handleBackspace(); handleBackspace();
mDeleteCount++; mDeleteCount++;
LatinImeLogger.logOnDelete(1);
break; break;
case Keyboard.KEYCODE_SHIFT: case Keyboard.KEYCODE_SHIFT:
handleShift(); handleShift();
@ -982,6 +983,7 @@ public class LatinIME extends InputMethodService
} else { } else {
handleCharacter(primaryCode, keyCodes); handleCharacter(primaryCode, keyCodes);
} }
LatinImeLogger.logOnInputChar(1);
// Cancel the just reverted state // Cancel the just reverted state
mJustRevertedSeparator = null; mJustRevertedSeparator = null;
} }

View File

@ -175,6 +175,9 @@ public class LatinImeLogger implements SharedPreferences.OnSharedPreferenceChang
} }
private void sendLogToDropBox(int tag, Object s) { private void sendLogToDropBox(int tag, Object s) {
if (DBG) {
Log.d(TAG, "SendLog: " + tag + ";" + s);
}
long now = System.currentTimeMillis(); long now = System.currentTimeMillis();
if (now - mLastTimeActive > MINIMUMSENDINTERVAL) { if (now - mLastTimeActive > MINIMUMSENDINTERVAL) {
// Send a log before adding an log entry if the last data is too old. // Send a log before adding an log entry if the last data is too old.