From 00b5a9add5da22d200c044c177ea5a921bd590eb Mon Sep 17 00:00:00 2001 From: boyu0 Date: Mon, 27 Jan 2014 18:22:35 +0800 Subject: [PATCH] issue #2920: fix indent --- extensions/GUI/CCEditBox/CCEditBoxImplIOS.mm | 34 ++++++++++---------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/extensions/GUI/CCEditBox/CCEditBoxImplIOS.mm b/extensions/GUI/CCEditBox/CCEditBoxImplIOS.mm index f3712d2444..8f0db2c967 100644 --- a/extensions/GUI/CCEditBox/CCEditBoxImplIOS.mm +++ b/extensions/GUI/CCEditBox/CCEditBoxImplIOS.mm @@ -331,24 +331,24 @@ void EditBoxImplIOS::placeInactiveLabels() void EditBoxImplIOS::setInactiveText(const char* pText) { - if(_systemControl.textField.secureTextEntry == YES) - { - std::string passwordString; - for(int i = 0; i < strlen(pText); ++i) - passwordString.append("\u25CF"); - _label->setString(passwordString.c_str()); - } - else - _label->setString(getText()); - - // Clip the text width to fit to the text box - float fMaxWidth = _editBox->getContentSize().width - CC_EDIT_BOX_PADDING * 2; - Rect clippingRect = _label->getTextureRect(); - if(clippingRect.size.width > fMaxWidth) + if(_systemControl.textField.secureTextEntry == YES) { - clippingRect.size.width = fMaxWidth; - _label->setTextureRect(clippingRect); - } + std::string passwordString; + for(int i = 0; i < strlen(pText); ++i) + passwordString.append("\u25CF"); + _label->setString(passwordString.c_str()); + } + else + _label->setString(getText()); + + // Clip the text width to fit to the text box + float fMaxWidth = _editBox->getContentSize().width - CC_EDIT_BOX_PADDING * 2; + Rect clippingRect = _label->getTextureRect(); + if(clippingRect.size.width > fMaxWidth) + { + clippingRect.size.width = fMaxWidth; + _label->setTextureRect(clippingRect); + } } void EditBoxImplIOS::setFont(const char* pFontName, int fontSize)