diff options
author | Yann Herklotz <ymherklotz@gmail.com> | 2017-12-23 01:37:09 +0000 |
---|---|---|
committer | Yann Herklotz <ymherklotz@gmail.com> | 2017-12-23 01:40:47 +0000 |
commit | ddd26ed83d3ac0335562f762ced273a1d62bd959 (patch) | |
tree | a697de87564846e784fd1256d71c94270d8ec51d /yage/core/inputmanager.cpp | |
parent | 0ac42fb77773e15b13f1ede01dd1efd920a8fb9b (diff) | |
download | YAGE-ddd26ed83d3ac0335562f762ced273a1d62bd959.tar.gz YAGE-ddd26ed83d3ac0335562f762ced273a1d62bd959.zip |
[Style] Updated style in files.
Diffstat (limited to 'yage/core/inputmanager.cpp')
-rw-r--r-- | yage/core/inputmanager.cpp | 33 |
1 files changed, 0 insertions, 33 deletions
diff --git a/yage/core/inputmanager.cpp b/yage/core/inputmanager.cpp deleted file mode 100644 index 1f324b9e..00000000 --- a/yage/core/inputmanager.cpp +++ /dev/null @@ -1,33 +0,0 @@ -/** --------------------------------------------------------------------------- - * @file: inputmanager.cpp - * - * Copyright (c) 2017 Yann Herklotz Grave <ymherklotz@gmail.com> - * MIT License, see LICENSE file for more details. - * ---------------------------------------------------------------------------- - */ - -#include <yage/core/inputmanager.h> - -namespace yage -{ - -void InputManager::keyPressed(unsigned key) -{ - key_map_[key] = true; -} - -void InputManager::keyReleased(unsigned key) -{ - key_map_[key] = false; -} - -bool InputManager::isKeyPressed(unsigned key) const -{ - auto key_index = key_map_.find(key); - if (key_index != key_map_.end()) { - return key_index->second; - } - return false; -} - -} // namespace yage |