mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-09 13:01:49 +00:00
add 'onfocus' ui event & optimize container:add
This commit is contained in:
parent
8e8cabf2d1
commit
1e90115a26
9 changed files with 31 additions and 10 deletions
|
|
@ -114,6 +114,8 @@ namespace gui {
|
|||
ActionsSet actions;
|
||||
/// @brief 'ondoubleclick' callbacks
|
||||
ActionsSet doubleClickCallbacks;
|
||||
/// @brief 'onfocus' callbacks
|
||||
ActionsSet focusCallbacks;
|
||||
/// @brief 'ondefocus' callbacks
|
||||
ActionsSet defocusCallbacks;
|
||||
/// @brief element tooltip text
|
||||
|
|
@ -173,9 +175,10 @@ namespace gui {
|
|||
|
||||
virtual UINode* listenAction(const onaction& action);
|
||||
virtual UINode* listenDoubleClick(const onaction& action);
|
||||
virtual UINode* listenFocus(const onaction& action);
|
||||
virtual UINode* listenDefocus(const onaction& action);
|
||||
|
||||
virtual void onFocus() {focused = true;}
|
||||
virtual void onFocus();
|
||||
virtual void doubleClick(int x, int y);
|
||||
virtual void click(int x, int y);
|
||||
virtual void clicked(Mousecode button) {}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue