| 188 | } |
| 189 | |
| 190 | void TextInputNode::onTextFieldChanged() |
| 191 | { |
| 192 | std::string str = sanitizeString(_textField->getString()); |
| 193 | bool didTextChange = (str != _previousString); |
| 194 | |
| 195 | if (didTextChange) |
| 196 | { |
| 197 | _previousString = str; |
| 198 | _textField->setString(str); |
| 199 | |
| 200 | updateDisplayedLabel(); |
| 201 | |
| 202 | if (_delegate) |
| 203 | _delegate->textChanged(this); |
| 204 | } |
| 205 | } |
| 206 | |
| 207 | void TextInputNode::onKeyPressed(EventKeyboard::KeyCode keyCode, Event* event) |
| 208 | { |
nothing calls this directly
no test coverage detected