Browse Source

Don't consume all keys in TextField. Don't deselect TextField with escape key.

tags/v2.0.0
Andrew Belt 3 years ago
parent
commit
b99a228f75
1 changed files with 0 additions and 8 deletions
  1. +0
    -8
      src/ui/TextField.cpp

+ 0
- 8
src/ui/TextField.cpp View File

@@ -236,20 +236,12 @@ void TextField::onSelectKey(const SelectKeyEvent& e) {
if (e.keyName != "") {
e.consume(this);
}
// Esc
if (e.key == GLFW_KEY_ESCAPE && (e.mods & RACK_MOD_MASK) == 0) {
APP->event->setSelected(NULL);
e.consume(this);
}

assert(0 <= cursor);
assert(cursor <= (int) text.size());
assert(0 <= selection);
assert(selection <= (int) text.size());
}

// Consume ALL keys with ALL actions
e.consume(this);
}

int TextField::getTextPosition(math::Vec mousePos) {


Loading…
Cancel
Save