mirror of
https://github.com/luanti-org/luanti.git
synced 2025-08-01 17:38:41 +00:00
Auto-toggle TouchControls in-game when receiving touch/mouse input
This commit is contained in:
parent
3c5f05b284
commit
4952f17df4
15 changed files with 152 additions and 89 deletions
|
@ -347,6 +347,9 @@ struct SEvent
|
|||
|
||||
//! Type of mouse event
|
||||
EMOUSE_INPUT_EVENT Event;
|
||||
|
||||
//! Is this a simulated mouse event generated by Minetest itself?
|
||||
bool Simulated;
|
||||
};
|
||||
|
||||
//! Any kind of keyboard event.
|
||||
|
@ -538,6 +541,11 @@ struct SEvent
|
|||
struct SUserEvent UserEvent;
|
||||
struct SApplicationEvent ApplicationEvent;
|
||||
};
|
||||
|
||||
SEvent() {
|
||||
// would be left uninitialized in many places otherwise
|
||||
MouseInput.Simulated = false;
|
||||
}
|
||||
};
|
||||
|
||||
//! Interface of an object which can receive events.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue