Skip to content
Snippets Groups Projects
  1. Jun 04, 2013
  2. Jun 03, 2013
    • Kurt Partridge's avatar
      Fix revert of committed words · 94ef5432
      Kurt Partridge authored
      Now that separators are put into their own LogUnits, they must be handled
      when going through a revert.
      
      Bug: 9088919
      
      Change-Id: Ibebd0752bb2fa38d74ac96001d63070dd419cee3
      94ef5432
    • Kurt Partridge's avatar
      Compare scrubbed strings when uncommitting LogUnits · f07024e0
      Kurt Partridge authored
      A LogUnit is only uncommitted if the LogUnit's word matches what is
      expected.  But a LogUnit never stores numbers, only scrubbed words that
      replace numbers with a special character.  So when uncommitting, the
      text from the TextView must also be scrubbed for the comparison to pass
      correctly.
      
      Bug: 9088919
      
      Change-Id: I9b56f10afce6d0cc84eb9ead3b9a9b1e061ae39c
      f07024e0
    • Kurt Partridge's avatar
      Uncommit separator LogUnits · bdff287a
      Kurt Partridge authored
      Now that separators have their own LogUnits, they must be uncommitted
      from the LogBuffer when backspacing over them.
      
      Bug: 9088919
      
      Change-Id: Ib36cc94939b93abe18850a06bced17caf8aaa5b9
      bdff287a
  3. Jun 02, 2013
  4. May 28, 2013
  5. May 23, 2013
  6. May 21, 2013
    • Kurt Partridge's avatar
      Always record word boundaries · 450d78b0
      Kurt Partridge authored
      Word boundaries are currently logged, but only if all the
      details of a word pass the privacy filter and are logged.
      
      This change records when a word is committed in all cases,
      but does not disclose the word contents or any data used in
      its construction.
      
      Addresses b/9070768
      
      Change-Id: I573679d0685c088aca65af99e46337a2f429f816
      450d78b0
    • Kurt Partridge's avatar
      Modify isAllowedToLog · 74a6196c
      Kurt Partridge authored
      Currently isAllowedToLog only checks the state of the
      ResearchLogger, and does not consider which log the data is
      going to.  This causes problems with the logs for Feedback.
      The Feedback log should inhibit normal logging procedures,
      but the system needs to be able to write specific data
      directly to it.
      
      This change renames to isAllowedToLogTo and adds the
      destination ResearchLog as a parameter.  A FeedbackLog is also
      added as a new class so it can be distinguished from other
      ResearchLogs.
      
      Change-Id: I5a1eea05bb040c26bf816b89179f44b3024fa2ad
      74a6196c
  7. May 17, 2013
    • Kurt Partridge's avatar
      Fix punctuation logging · 500dea6a
      Kurt Partridge authored
      Punctuation is currently put into the same LogUnit as the
      following word.  This is counter-intuitive and makes
      post-processing more complicated.
      
      This change causes punctuation to be put into its own
      LogUnit.
      
      A tricky case is the phantom space.  A phantom space is
      inserted right before other text, whose MotionEvents have
      already been collected and inserted into mCurrentLogBuffer.
      Phantom spaces are handled by creating their own LogUnit and
      inserting it into the LogBuffer right before
      mCurrentLogBuffer is shifted in.
      
      Change-Id: I102d7cd93982ad37ba0abb6c1ac0f66b85b5f95d
      500dea6a
  8. May 14, 2013
    • Kurt Partridge's avatar
      Remove unnecessary commit/uncommit · 993acbaa
      Kurt Partridge authored
      When the user reverts a commit, this causes the committed
      word to be changed. The user usually then goes back to edit
      that word.  Going back to edit causes an uncommit, so that
      the editing actions are added onto the LogUnit containing
      the operations used to construct the word.
      
      But currently, reverting also involves its own
      commit/uncommit pair, with the caller performing the
      uncommit, and the commit happening inside the revert
      command.  This may have been necessary in the past, when
      revert was called in different situations, but is
      unnecessary now.  Furthermore, the guarding conditions are
      currently such that the uncommit doesn't always undo the
      effects of the commit, corrupting the log output.
      
      Change-Id: I74af41f4f1db2fcabfa496dcc4a2d7bd0af19b3a
      993acbaa
    • Kurt Partridge's avatar
      Remove FeedbackLog instance variables. · 6fefc142
      Kurt Partridge authored
      For a while, the ResearchLogger supported comprehensive recording of the
      last few words in case the user wished to upload this data to give
      developers feedback.  However, this mechanism was not implemented well
      (keeping a separate copy of the data), did not make the collected data
      clear to the user, and was not working properly in the latest build (NPEs).
      The mechanism in fact was deprecated in favor of the "userRecording"
      mechanism in which the user explicitly turned on comprehensive recording,
      demonstrated the issue they were experiencing, and then turned it off.
      
      This change removes the vestiges of the FeedbackLogging mechanism.
      A feedback log is still used to hold the user's message, but it is created
      in a local variable as-needed, and not persisted in ResearchLogger.
      
      Change-Id: I6a09d0ed36e1eddb6e57895e7428d22107f75f49
      6fefc142
  9. May 11, 2013
    • Kurt Partridge's avatar
      Avoid JsonWriter multi-write error · 7d72ca0b
      Kurt Partridge authored
      JsonWriter requires that its clients pass it only a single top-level object.
      The existing implementation tries to make code cleaner by having mJsonWriter
      never be null, and instead use a global static "NULL_JSON_WRITER" that just
      discards data.  But because JsonWriter complains if more than one top-level
      object is passed, making this a global object does not work.  This change
      instead copes with mJsonWriter being null.
      
      Change-Id: Ia37ccfc8646e91f11a64713dd92d2846eb86ac54
      7d72ca0b
  10. May 10, 2013
    • Kurt Partridge's avatar
      Avoid NPE by fixing ResearchLogger initialization · a68cace7
      Kurt Partridge authored
      Previously, mMainResearchLog and mMainLogBuffer were set up
      when the user moved to a new TextView, and set to null when
      the user left the TextView.  This change causes
      mMainResearchLog, mMainLogBuffer, mFeedbackLog, and
      mFeedbackLogBuffer to be non-null forever after init() is
      called.  start() no longer sets up these fields; instead
      they are cleared and reset every time stop() is called.
      Checks for null values are now removed.
      
      The earlier code just didn't initialize these variables if
      the user disabled logging, but since the new version
      invariantly keeps these variables valid, we add a check for
      whether the user has enabled logging in publishLogUnits().
      
      Change-Id: Ifde3517f1cf924cfa33cda95fec24529b52b3c08
      a68cace7
  11. May 09, 2013
    • Kurt Partridge's avatar
      Remove unused code · 01163416
      Kurt Partridge authored
      Change-Id: I192c67e9e8de44f073abc70ec85ebcdb36356c2e
      01163416
    • Kurt Partridge's avatar
      Remove ref to LatinImeLogger preference. · ef5d760c
      Kurt Partridge authored
      This is a bug; the ResearchLogger uses ResearchSettings.readResearchLoggerEnabledFlag() instead,
      which the user cannot change.  (We assume they will just switch to a different keyboard.)
      
      Change-Id: Ib5731c9eeb2bc29d9cf8608033326674f5eb6f7b
      ef5d760c
  12. Apr 19, 2013
    • Kurt Partridge's avatar
      Allow LogUnits to hold >1 word · e92b5e14
      Kurt Partridge authored
      LogUnits have been annotated with the autocorrected words, but
      until now this was assumed to be a single word without spaces.
      But spaceless typing can result in spaces in the LogUnit label.  With this
      change, the LogUnit inspects the autocorrected text to determine how many
      words were inserted, and counts them accurately.
      
      This change corrects a privacy problem, which was that if the word sampling
      algorithm chose a LogUnit that actually contained multiple words, then more
      than two successive words would be included in the log.
      
      Change-Id: I7c01c3dd3ac33d7e96c00836256bae9c14b124ed
      e92b5e14
  13. Apr 17, 2013
    • Kurt Partridge's avatar
      Label logUnits after LatinImeOnEndBatchInput · fe052971
      Kurt Partridge authored
      Previously only a commitText would cause a LogUnit to be
      labeled with the word that the data generates.  In the case
      of gestured text, this information is available when
      LatinIME#onEndBatchInput is called. Labeling the LogUnit
      at this time means that the Log will have labeled words even
      if stop() is called before commit.
      
      Change-Id: Idb2f99a9c159a1b1aa00448a2ecddeca6c351c3e
      fe052971
    • Kurt Partridge's avatar
      Fix NPE · 4ac28ded
      Kurt Partridge authored
      Change-Id: I8a091fb63dab12a0d2ba69e2fe393249bc68d103
      4ac28ded
    • Kurt Partridge's avatar
      Fix logic error · cd39368c
      Kurt Partridge authored
      Change-Id: Ia36660c66504ba2fbb7f125704926a08726df87a
      cd39368c
    • Kurt Partridge's avatar
      Small dot in corner was not visible · 2d9d4390
      Kurt Partridge authored
      Framework change perhaps?  Even if not, this makes it more visible
      
      Change-Id: Ib6d36b5a30136c4516adac666bdff36d1cd9b337
      2d9d4390
    • Kurt Partridge's avatar
      Include nanoTime in filename · 125f22dc
      Kurt Partridge authored
      System is fast enough that sometimes SystemClock.currentTimeMillis() is duplicated
      when used to make a unique filename.
      
      Change-Id: I9454fbb5e10265d36b8e17cba183a1591d52cc7b
      125f22dc
  14. Apr 12, 2013
    • Jean Chalard's avatar
      Restart suggestions when the cursor moves. · 6a114fa7
      Jean Chalard authored
      This uses the old suggestions. It does not try to recompute
      new suggestions if there are no old suggestions yet: this is
      coming in a later change.
      If there are no suggestions, this shows the word itself
      as a suggestion.
      
      Bug: 8084810
      Change-Id: I4c2e25df0ff3673be1825f57a0c19a9d23d47a48
      6a114fa7
  15. Apr 10, 2013
    • Kurt Partridge's avatar
      Better isolate ResearchLogging data · 6108624a
      Kurt Partridge authored
      Calls to LatinIME#onStartInputViewInternal log important information
      about the context in which an IME is used.  This is reported as a
      single LogStatement.  Previously, this was not placed into a separate
      LogUnit, and was mixed in with general word data.  This change wraps
      this LogStatement in its own LogUnit.
      
      Change-Id: I0fecd41c8a1de622a764cc4b5d6902336697046c
      6108624a
    • Kurt Partridge's avatar
      Better release build reporting · dfa5628c
      Kurt Partridge authored
      The ResearchLogger reports whether a build is a release build or not
      to avoid polluting data with IME debugging work by developers.
      Previously this was done by checking a constant flag, which was also
      serving the dual purpose of masking out debug code in release builds.
      
      This change introduces a heuristic to determine whether a build was
      created by a developer (using the package versionName), and annotating
      the data sent to the server appropriately.
      
      Change-Id: Icbad17c66b703cabf6d23d05e2c7c41bcceaae45
      dfa5628c
  16. Apr 01, 2013
    • Kurt Partridge's avatar
      Allow logging while replaying · 30772c37
      Kurt Partridge authored
      Previously logging was disabled during replay.  This makes it impossible to use logged data as a
      regression test, since the new log was unavailable.  This change corrects this problem.
      
      Change-Id: I19dc31def2f2f87fd219dc561c739d18e4ab9c9c
      30772c37
  17. Mar 26, 2013
    • Kurt Partridge's avatar
      Avoid NPE · 39cb0334
      Kurt Partridge authored
      Initialize FeedbackLog earlier to avoid NPE
      
      Change-Id: I646944c68a7d092345def16060b2a4edd8c7dbef
      39cb0334
    • Kurt Partridge's avatar
      Split LogUnits differently. · 189be519
      Kurt Partridge authored
      Previously an autocorrection caused a new LogUnit to be started,
      splitting off the previous LogUnit right at the autocorrection method
      time.  This change causes the split to happen before the MotionEvents
      that led to the autocorrection being called.
      
      Change-Id: I2504df8eb47ee77e5f46bac34a8450636c03fd9f
      189be519
    • Kurt Partridge's avatar
      [FileEncap18] Clean up uploading scheduling · 6d71d238
      Kurt Partridge authored
      - Move scheduling logic from ResearchLogger.java to
        UploaderService.java
      - Switch to a one-shot timer.  Previously the uploader was scheduled
        on an inexact repeating schedule.  It's better to reschedule the
        next upload after the current one is finished to reduce the chances
        of multiple uploads happening at the same time.
      - Avoid double-execution
          - Previously a scheduled upload might run right after an explicit
            one if they occured at the same time.  This change reduces the
            chances of this.
      - Some method extraction and naming
      
      Change-Id: I9efda11be77d334c7f61bd40a36d65f0421ebde4
      6d71d238
    • Kurt Partridge's avatar
      Close ResearchLogger upon onFinishInputView · 87bc3a4a
      Kurt Partridge authored
      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
      87bc3a4a
  18. Mar 18, 2013
  19. Mar 14, 2013
    • Kurt Partridge's avatar
      [FileEncap9] Extract ResearchLogDirectory class · f33f1cab
      Kurt Partridge authored
      Previously used a monotonically increasing int.  Now uses uuid and nanoseconds.
      
      squashed in:
          [FileEncap11] Read preference from ResearchSettings
          Change-Id: Ic779e0a69db6b16e92c6f4b63dbe7b7add566ab6
      
          [FileEncap12] Simplify directory cleanup invocation
          Change-Id: I688047409c0343d32b11447fb625dfb726c731ec
      
          [FileEncap14] Change log filename syntax
          Change-Id: I9243b20b2eb392f81ab8c5c3d19315211240e0bc
      
      Change-Id: I5c9d70e0cb7b0965158e17dd71dfab796bd9a440
      f33f1cab
  20. Mar 13, 2013
  21. Mar 06, 2013
  22. Mar 04, 2013
    • Kurt Partridge's avatar
      Clean up logic in onUserLoggingConsent · 157c0014
      Kurt Partridge authored
      - Make ResearchSetting for whether the user has seen the splash screen
      - Inline #setLoggingAllowed, which is short and is now only called by
        onUserLoggingConsent
      
      Change-Id: Icdf4592777b80643807b6ccf1d3896459c503e02
      157c0014
    • Kurt Partridge's avatar
      Clean up PREF_USABILITY_STUDY_MODE · 75e6fb68
      Kurt Partridge authored
      - Refer to a common default value in DebugSettings
      - Make PREF_USABILITY_STUDY_MODE independent of the ResearchLogger
      - ResearchLogger uses its own preference through ResearchSettings
      
      multi-project commit with Ie0df836c9d779eba484b522666ec357f4e234823
      
      Change-Id: I88547a2f619db6e7364abbbec12f9f76855dd11a
      75e6fb68
  23. Mar 01, 2013
Loading