mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-27 22:49:25 +02:00
Code review tweaks
This commit is contained in:
@@ -607,7 +607,7 @@ void CTextInput::keyPressed(EShortcut key)
|
||||
|
||||
void CTextInput::showPopupWindow(const Point & cursorPosition)
|
||||
{
|
||||
if(helpBox.size()) //there is no point to show window with nothing inside...
|
||||
if(!helpBox.empty()) //there is no point to show window with nothing inside...
|
||||
CRClickPopup::createAndPush(helpBox);
|
||||
}
|
||||
|
||||
@@ -624,6 +624,11 @@ void CTextInput::setText(const std::string & nText, bool callCb)
|
||||
cb(text);
|
||||
}
|
||||
|
||||
void CTextInput::setHelpText(const std::string & text)
|
||||
{
|
||||
helpBox = text;
|
||||
}
|
||||
|
||||
void CTextInput::textInputed(const std::string & enteredText)
|
||||
{
|
||||
if(!focus)
|
||||
|
||||
Reference in New Issue
Block a user