summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/bgfx/examples/common/entry/input.cpp
diff options
context:
space:
mode:
author ImJezze <jezze@gmx.net>2016-03-12 12:31:13 +0100
committer ImJezze <jezze@gmx.net>2016-03-12 12:31:13 +0100
commita026a582f1a0ea8c1ede3acaddacef506ef3f3b0 (patch)
treee31573822f2359677de519f9f3b600d98e8764cd /3rdparty/bgfx/examples/common/entry/input.cpp
parent477d2abd43984f076b7e45f5527591fa8fd0d241 (diff)
parentdcab55bf53b94713a6f72e9633f5101c8dd6c08c (diff)
Merge pull request #15 from mamedev/master
Sync to base master
Diffstat (limited to '3rdparty/bgfx/examples/common/entry/input.cpp')
-rw-r--r--3rdparty/bgfx/examples/common/entry/input.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/3rdparty/bgfx/examples/common/entry/input.cpp b/3rdparty/bgfx/examples/common/entry/input.cpp
index c0d2686d293..bb9925990b0 100644
--- a/3rdparty/bgfx/examples/common/entry/input.cpp
+++ b/3rdparty/bgfx/examples/common/entry/input.cpp
@@ -11,6 +11,7 @@
#include <bx/allocator.h>
#include <bx/ringbuffer.h>
+#include <tinystl/string.h>
#include <tinystl/allocator.h>
#include <tinystl/unordered_map.h>
namespace stl = tinystl;
@@ -197,12 +198,12 @@ struct Input
void addBindings(const char* _name, const InputBinding* _bindings)
{
- m_inputBindingsMap.insert(stl::make_pair(_name, _bindings) );
+ m_inputBindingsMap.insert(stl::make_pair(stl::string(_name), _bindings) );
}
void removeBindings(const char* _name)
{
- InputBindingMap::iterator it = m_inputBindingsMap.find(_name);
+ InputBindingMap::iterator it = m_inputBindingsMap.find(stl::string(_name));
if (it != m_inputBindingsMap.end() )
{
m_inputBindingsMap.erase(it);
@@ -275,7 +276,7 @@ struct Input
}
}
- typedef stl::unordered_map<const char*, const InputBinding*> InputBindingMap;
+ typedef stl::unordered_map<stl::string, const InputBinding*> InputBindingMap;
InputBindingMap m_inputBindingsMap;
Mouse m_mouse;
Keyboard m_keyboard;