From cbed462d192d0c5af9614f5f997b2768f3d0eb56 Mon Sep 17 00:00:00 2001 From: Jean Chalard Date: Thu, 20 Mar 2014 17:55:30 +0900 Subject: [CB12] Reset the combining state when resetting the composer Bug: 13406701 Change-Id: I490574b7ca4b953f67dd2c0ef97401297fade0a4 --- java/src/com/android/inputmethod/event/CombinerChain.java | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'java/src/com/android/inputmethod/event/CombinerChain.java') diff --git a/java/src/com/android/inputmethod/event/CombinerChain.java b/java/src/com/android/inputmethod/event/CombinerChain.java index cf2a4d1a1..5ca9842c1 100644 --- a/java/src/com/android/inputmethod/event/CombinerChain.java +++ b/java/src/com/android/inputmethod/event/CombinerChain.java @@ -58,6 +58,14 @@ public class CombinerChain { mStateFeedback = new SpannableStringBuilder(); } + public void reset() { + mCombinedText.setLength(0); + mStateFeedback.clear(); + for (final Combiner c : mCombiners) { + c.reset(); + } + } + /** * Pass a new event through the whole chain. * @param previousEvents the list of previous events in this composition -- cgit v1.2.3-83-g751a