Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8149820c authored by Sascha Prueter's avatar Sascha Prueter Committed by Android Git Automerger
Browse files

am 25458528: am dd2ed93e: Merge "Handle "CODE_ALREADY_PRESENT" message from...

am 25458528: am dd2ed93e: Merge "Handle "CODE_ALREADY_PRESENT" message from Settings app" into jb-mr1.1-dev

* commit '25458528':
  Handle "CODE_ALREADY_PRESENT" message from Settings app
parents 1d349dd4 25458528
Loading
Loading
Loading
Loading
+13 −9
Original line number Diff line number Diff line
@@ -3849,8 +3849,9 @@ public class Editor {

        @Override
        public void handleMessage(Message msg) {
            final int code = msg.what;
            if (code == 0) { /* CODE_WORD_ADDED */
            switch(msg.what) {
                case 0: /* CODE_WORD_ADDED */
                case 2: /* CODE_ALREADY_PRESENT */
                    if (!(msg.obj instanceof Bundle)) {
                        Log.w(TAG, "Illegal message. Abort handling onUserDictionaryAdded.");
                        return;
@@ -3859,6 +3860,9 @@ public class Editor {
                    final String originalWord = bundle.getString("originalWord");
                    final String addedWord = bundle.getString("word");
                    onUserDictionaryAdded(originalWord, addedWord);
                    return;
                default:
                    return;
            }
        }