mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-06 19:41:51 +00:00
minor refactor
This commit is contained in:
parent
8de986346e
commit
60cfe8595e
3 changed files with 11 additions and 7 deletions
|
|
@ -88,8 +88,7 @@ void Events::pollEvents() {
|
|||
binding.justChange = true;
|
||||
binding.onactived.notify();
|
||||
}
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
if (binding.state) {
|
||||
binding.state = false;
|
||||
binding.justChange = true;
|
||||
|
|
@ -107,7 +106,7 @@ void Events::bind(const std::string& name, inputtype type, mousecode code) {
|
|||
}
|
||||
|
||||
void Events::bind(const std::string& name, inputtype type, int code) {
|
||||
bindings[name] = Binding(type, code);
|
||||
bindings.emplace(name, Binding(type, code));
|
||||
}
|
||||
|
||||
bool Events::active(const std::string& name) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue