Skip to content
Snippets Groups Projects
  1. Oct 01, 2014
  2. Sep 29, 2014
  3. Sep 18, 2014
    • Yohei Yukawa's avatar
      Use Add-To-Dictionary indicator only · 5896153f
      Yohei Yukawa authored
      With this CL, the previously used commit indicator was reverted.
      Instead we use the add-to-dictionary indicator only at the moment.
      
      This CL also fixes the indicator position in bidi context.
      
      BUG: 17335734
      Change-Id: I5f7cf173ddc30876e2b01320acaff8ba4265edf6
      5896153f
  4. Sep 08, 2014
  5. Sep 03, 2014
    • Yohei Yukawa's avatar
      Follow up API signature change · 5d6ac777
      Yohei Yukawa authored
      This is a follow up CL for API signature change in
      I772c48ff18918e48a81e807b48ff907614485c09
      
      BUG: 17320996
      Change-Id: Ic8b6162bda12bf74fae79af212c5d81c400eb9e8
      5d6ac777
  6. Aug 27, 2014
    • Yohei Yukawa's avatar
      Make sure to obtain the IC before requesting CursorAnchorInfo · acce1aa5
      Yohei Yukawa authored
      RichInputConnection#requestUpdateCursorAnchorInfo must make
      sure to obtain the input connection before calling methods
      of it.
      
      BUG: 17299587
      Change-Id: I8e0cd473a4cc32583cd47634c227d702f7c69c6c
      acce1aa5
    • Yohei Yukawa's avatar
      Set the text bgcolor only when CursorAnchorInfo is available · 29200b0a
      Yohei Yukawa authored
      When CursorAnchorInfo is unavailable, we shouldn't try to show
      the commit indicator and set the text highlight color.
      
      With this CL, RichInputConnection can be used to track if the
      application responded that it does support CursorAnchorInfo or
      not.  This result will be taken into consideration when
      InputLogic needs to determine whether the commit indicator
      should be displayed or not.
      
      Change-Id: I945d70eeb02a7a5f3d9b22459b23d7028508910f
      29200b0a
  7. Aug 25, 2014
    • Yohei Yukawa's avatar
      Allow to add/remove background color to/from the committed text · 4a71d2c4
      Yohei Yukawa authored
      This is a groundwork for subsequent CLs where we need to
      add/remove background color to/from the commited text.
      
      In this CL, we use Spanned#SPAN_COMPOSING so that we can easily
      remove such a background color by calling
      InputConnection#finishComposingText. To make this operation easy
      and realiable, we need to track whether we have specified the
      background color to the commited text or not at one place. Here
      we use RichInputConnection for this purpose.
      
      Change-Id: I5f9bc4425c5d1b80a719a20e5baf336729ec08d2
      4a71d2c4
  8. Aug 06, 2014
    • Jean Chalard's avatar
      [HS3] Fix a bug on ICS · 9273f383
      Jean Chalard authored
      There is a bug in ICS where the input connection won't take
      any writing commands after rotation until the cursor moves.
      This fixes it by wiggling the cursor position once before trying
      to do anything.
      
      Bug: 16810766
      Change-Id: Ib14c70bd0550420cecfa86dea501d13a1a91e296
      9273f383
  9. Jul 07, 2014
  10. Jul 01, 2014
  11. Jun 30, 2014
  12. Jun 27, 2014
  13. Jul 01, 2014
  14. Jun 30, 2014
  15. Jun 27, 2014
  16. Jun 25, 2014
  17. Jun 06, 2014
    • Jean Chalard's avatar
      Fix a bug on rotation with selection. · 9fd9a68d
      Jean Chalard authored
      The symptom : when text is selected and the device is rotated,
      sometimes the keyboard sets the word as being composed around
      the start of the selection. Upon the next rotation this ends up
      with the keyboard committing some text in place of the selection.
      
      The cause : another bug in the framework with rotation >.>
      The keyboard receives a call to startInput with a wrong cursor
      position, namely one that does not represent a selection. The
      keyboard sets a composition according to this wrong data. When
      the keyboard is rotated again, it commits the text, which takes
      the place of the selection.
      
      The solution : actually when restarting input the keyboard
      realizes that the cursor position is wrong. We cancel composition
      at that time.
      For robustness, this change also implements two other defensive
      changes : upon call to onUpdateSelection, we actually realize
      that the previous values were wrong, so we also fix it at that
      time, and in addition, when rotating, we finishComposingText()
      instead of commitText() which is less dangerous. Implementing
      this later change also allows us to let less internal variables
      from InputLogic escape to LatinIME, so it's also a good change
      for design.
      
      Bug: 14140799
      
      Change-Id: Ib10de18e53e376ac1bbc8487e13d969828483346
      9fd9a68d
  18. May 30, 2014
  19. May 29, 2014
  20. May 23, 2014
  21. May 21, 2014
  22. Mar 20, 2014
  23. Mar 10, 2014
  24. Feb 24, 2014
  25. Feb 20, 2014
    • Jean Chalard's avatar
      Change a heuristic and add a log. · 3b4c1d30
      Jean Chalard authored
      The heuristic in RichInputConnection makes little sense
      when textLength > mExpectedSelStart but we have
      more than 1024 characters of text. If there are that many,
      it's about 100% sure that 1024 is not the correct cursor
      position. With no good guess, we'll just continue trusting
      the app, even though we know it's lying : at least it will
      make the problem visible to the app author.
      
      Also, there have been a lot of confusion about initialSelStart
      and initialSelEnd. The keyboard should log them so that
      it helps us and editor authors debug more easily these
      common problems.
      
      Issue #65170 in AOSP and
      Bug: 12772035
      Change-Id: I6665a16c9f2832d33ee323f033bb38bcc092a3b4
      3b4c1d30
    • Jean Chalard's avatar
      Don't distrust the cursor pos so much as to bug on IPC delay · 3c84eb88
      Jean Chalard authored
      When the cursor is moved by the user, the RichInputConnection
      is told about it. However, to work around a framework bug, it
      also looks at how many characters are in the buffer before the
      cursor, and if that's more than the value it's been passed, it
      deduces that's a framework bug and there are at least as many
      characters as seen before the cursor, so it puts the expected
      cursor position there.
      
      When you move the cursor, TextView calls onUpdateSelection,
      and when you move it fast, you'll get rapid-fire calls to
      onUpdateSelection. This is fine, the RIC is equipped to
      deal with that.
      
      However, these calls take some time to make it to the IME. In
      this instance, when the first call gets through and the IME
      calls TextView (synchronously) for text before the cursor, the
      cursor has already moved in the app, and TextView returns more
      characters than the cursor position was declared to be in this
      instance, so the RIC sets that as the expected cursor position.
      Sure enough, a split second later, the second call to
      onUpdateSelection arrives, with the new cursor position set
      where the RIC had found it too early. The RIC takes that as an
      "expected" cursor move, and the input does not get reset.
      
      Luckily, we have a way out. As far as we know, the framework bug
      only manifests itself upon rotation, which means we should only
      have to adjust for it in onStartInputView. Doing it in
      onUpdateSelection is too zealous (and probably too distrustful of
      the app to send the correct cursor positions).
      
      So we should just take care of the rotation case (by calling
      tryFixLyingCursorPosition in onStartInputView) and remove the
      compensating code in resetCachesUponCursorMoves.
      
      Bug: 12982502
      Change-Id: Ic3c1408a1ec45deaea63b01d98376a79ae567d77
      3c84eb88
    • Jean Chalard's avatar
      Comments improvements · be8ad77e
      Jean Chalard authored
      Typo fixes and clarifications
      
      Change-Id: I0f7e0b6e665232bb995172fff10521c7f17599eb
      be8ad77e
  26. Feb 18, 2014
    • Jean Chalard's avatar
      Fix a bug where the cache would be out of sync · fe92c174
      Jean Chalard authored
      During recorrection, the cursor position when calling
      commitText is not necessarily at the end of the
      composing text.
      Besides, RichInputConnection assumes the cursor is
      always after any composing text. This is not correct,
      but in the practice, it seems all code paths work.
      We should fix this in the future.
      
      Bug: 13060691
      Change-Id: I15f71fff62d36e80cf6e4a022c5e78af634b199d
      fe92c174
  27. Feb 17, 2014
  28. Jan 27, 2014
  29. Jan 20, 2014
  30. Jan 17, 2014
  31. Jan 10, 2014
Loading