mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 10:37:45 +00:00
Spreadsheet: Keep value when clicking out of a cell
This commit is contained in:
parent
73b9cfac1b
commit
6219c3ec3c
2 changed files with 7 additions and 0 deletions
|
@ -124,10 +124,14 @@ private:
|
|||
commit();
|
||||
on_cursor_key_pressed(event);
|
||||
};
|
||||
textbox->on_focusout = [this] {
|
||||
on_cell_focusout(index(), value());
|
||||
};
|
||||
return textbox;
|
||||
}
|
||||
|
||||
Function<void(GUI::KeyEvent&)> on_cursor_key_pressed;
|
||||
Function<void(const GUI::ModelIndex&, const GUI::Variant&)> on_cell_focusout;
|
||||
|
||||
private:
|
||||
bool m_has_set_initial_value { false };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue