mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-06 11:31:49 +00:00
fix: manually changing textbox.caret does not reset selection
This commit is contained in:
parent
7fb51526fd
commit
843cc3769d
2 changed files with 2 additions and 1 deletions
|
|
@ -759,6 +759,7 @@ static void p_set_text(UINode* node, lua::State* L, int idx) {
|
|||
static void p_set_caret(UINode* node, lua::State* L, int idx) {
|
||||
if (auto box = dynamic_cast<TextBox*>(node)) {
|
||||
box->setCaret(static_cast<ptrdiff_t>(lua::tointeger(L, idx)));
|
||||
box->resetSelection();
|
||||
}
|
||||
}
|
||||
static void p_set_editable(UINode* node, lua::State* L, int idx) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue