bug 634555 - Caret is misplaced before the last typed in character when entering characters in input fields r=mwu a=blocking-fennec
authorBrad Lassey <blassey@mozilla.com>
Wed, 23 Feb 2011 11:22:43 -0500
changeset 62994 5aa946c77f698416f4cf5713bbba27277fcd8d55
parent 62993 056c9ea05c26bc99f2c2ede5713f44f80f0c09f5
child 62995 8a4f5201dc6a53bf9e81f813eabd32dcde91882c
push id1
push userroot
push dateTue, 10 Dec 2013 15:46:25 +0000
reviewersmwu, blocking-fennec
bugs634555
milestone2.0b13pre
bug 634555 - Caret is misplaced before the last typed in character when entering characters in input fields r=mwu a=blocking-fennec
embedding/android/GeckoInputConnection.java
--- a/embedding/android/GeckoInputConnection.java
+++ b/embedding/android/GeckoInputConnection.java
@@ -553,16 +553,21 @@ public class GeckoInputConnection
 
             GeckoAppShell.sendEventToGecko(
                 new GeckoEvent(0, count,
                                GeckoEvent.IME_RANGE_RAWINPUT, 0, 0, 0,
                                s.subSequence(start, start + count).toString()));
 
             GeckoAppShell.sendEventToGecko(
                 new GeckoEvent(GeckoEvent.IME_COMPOSITION_END, 0, 0));
+
+            GeckoAppShell.sendEventToGecko(
+                new GeckoEvent(GeckoEvent.IME_SET_SELECTION, start + count, 0));
+
+            
         }
     }
 
     public void afterTextChanged(Editable s)
     {
     }
 
     public void beforeTextChanged(CharSequence s, int start, int count, int after)