summaryrefslogtreecommitdiffstats
path: root/src/controller_hooks.hpp
diff options
context:
space:
mode:
authorMarcus Fritzsch <marcus_fritzsch@mentor.com>2017-08-02 16:16:15 +0200
committerMarcus Fritzsch <marcus_fritzsch@mentor.com>2017-08-08 17:24:00 +0200
commit93c2a361b2144d82ec70208225c45afd8f355bd3 (patch)
tree43801ffca32edaec732b391f4bbf5633de09f6cf /src/controller_hooks.hpp
parent9b094f7e17736529e8fd1d25515112f9a1a2daac (diff)
app/wayland: move late-tasks to App
* Move late-tasks to App. * Add add_task() to controller_hooks. * Do not roundtrip at the end of App::execute_pending(), flush() is enough. * Tasks are now void() functions, need to capture what is needed. Signed-off-by: Marcus Fritzsch <marcus_fritzsch@mentor.com>
Diffstat (limited to 'src/controller_hooks.hpp')
-rw-r--r--src/controller_hooks.hpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/controller_hooks.hpp b/src/controller_hooks.hpp
index 47ab0ec..8618edc 100644
--- a/src/controller_hooks.hpp
+++ b/src/controller_hooks.hpp
@@ -23,6 +23,8 @@
#include <cstdint>
+#include <functional>
+
namespace wm {
struct App;
@@ -33,6 +35,8 @@ struct controller_hooks {
void surface_created(uint32_t surface_id);
void surface_removed(uint32_t surface_id);
+
+ void add_task(char const *name, std::function<void()> &&);
};
} // namespace wm