Browse Source

force focus to text input dialogs

Signed-off-by: falkTX <falktx@falktx.com>
tags/23.07
falkTX 2 years ago
parent
commit
aac3edc1e2
Signed by: falkTX <falktx@falktx.com> GPG Key ID: CDBAA37ABC74FBA0
1 changed files with 4 additions and 0 deletions
  1. +4
    -0
      src/AsyncDialog.cpp

+ 4
- 0
src/AsyncDialog.cpp View File

@@ -220,6 +220,10 @@ struct AsyncTextInput : OpaqueWidget
}
TextField::onSelectKey(e);
}
void step() override {
APP->event->setSelectedWidget(this);
TextField::step();
}
};
AsyncTextField* const textField = new AsyncTextField;
textField->box.size.x = contentLayout->box.size.x - (label != nullptr ? label->box.size.x + margin : 0);


Loading…
Cancel
Save