From 6f99e161f8c15c643915bbb3224eeaba5e581b28 Mon Sep 17 00:00:00 2001 From: Jialong Zhai <15759266583@163.com> Date: Mon, 12 Jan 2015 10:18:55 +0800 Subject: [PATCH] Change the order of detach and attach of TextField::upadate --- cocos/ui/UITextField.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/cocos/ui/UITextField.cpp b/cocos/ui/UITextField.cpp index a4bb810d07..055ba6f551 100644 --- a/cocos/ui/UITextField.cpp +++ b/cocos/ui/UITextField.cpp @@ -594,16 +594,16 @@ const char* TextField::getPasswordStyleText()const void TextField::update(float dt) { - if (getAttachWithIME()) - { - attachWithIMEEvent(); - setAttachWithIME(false); - } if (getDetachWithIME()) { detachWithIMEEvent(); setDetachWithIME(false); } + if (getAttachWithIME()) + { + attachWithIMEEvent(); + setAttachWithIME(false); + } if (getInsertText()) { insertTextEvent();