diff options
author | 2017-06-23 15:37:34 +0200 | |
---|---|---|
committer | 2017-08-08 17:24:00 +0200 | |
commit | 0b465f48da16c2e4f634a53892705c7ecc885ece (patch) | |
tree | 8ac4f464f86e1667f8e33fe94c08aa5c385fad0d /src/wayland.hpp | |
parent | 10d979c88cdcbab18e3401427f981e22d80ce8bb (diff) |
use unordered_map for id->obj maps
Signed-off-by: Marcus Fritzsch <marcus_fritzsch@mentor.com>
Diffstat (limited to 'src/wayland.hpp')
-rw-r--r-- | src/wayland.hpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/wayland.hpp b/src/wayland.hpp index da3cc29..df9b68e 100644 --- a/src/wayland.hpp +++ b/src/wayland.hpp @@ -6,7 +6,7 @@ #include "util.h" #include <functional> -#include <map> +#include <unordered_map> #include <memory> #include <vector> @@ -69,7 +69,7 @@ struct display { // |___/ |___/ struct registry : public wayland_proxy<struct wl_registry> { typedef std::function<void(struct wl_registry *, uint32_t, uint32_t)> binder; - std::map<std::string, binder> bindings; + std::unordered_map<std::string, binder> bindings; registry(struct wl_display *d); ~registry(); @@ -298,9 +298,9 @@ struct screen : public wayland_proxy<struct ivi_controller_screen>, // \___\___/|_| |_|\__|_| \___/|_|_|\___|_| // struct controller : public wayland_proxy<struct ivi_controller> { - std::map<uint32_t, std::unique_ptr<struct surface>> surfaces; - std::map<uint32_t, std::unique_ptr<struct layer>> layers; - std::map<uint32_t, std::unique_ptr<struct screen>> screens; + std::unordered_map<uint32_t, std::unique_ptr<struct surface>> surfaces; + std::unordered_map<uint32_t, std::unique_ptr<struct layer>> layers; + std::unordered_map<uint32_t, std::unique_ptr<struct screen>> screens; typedef std::pair<char const *, std::function<void(struct controller *)>> name_task_pair; |