X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=src%2Fapp.hpp;h=5ef7ab4ac8434cd64db6293857fc70ca5ce6f612;hb=6a10feaafbe80f7c3738535dfd7ca97f00e1f405;hp=297b6af1ad0fc1d3f2d9adb56d5ffc071b65a451;hpb=e2a149b190298bc60e9f952f119d52a1b3ddc9d6;p=staging%2Fwindowmanager.git diff --git a/src/app.hpp b/src/app.hpp index 297b6af..5ef7ab4 100644 --- a/src/app.hpp +++ b/src/app.hpp @@ -127,8 +127,6 @@ struct App { return this->id_alloc.lookup(id); } - struct LayoutState state; - // Set by AFB API when wayland events need to be dispatched std::atomic pending_events; void set_pending_events() { @@ -140,6 +138,10 @@ struct App { x, false, std::memory_order_consume); } + std::vector pending_end_draw; + void enqueue_flushdraw(int surface_id); + void check_flushdraw(int surface_id); + explicit App(wl::display *d); ~App(); @@ -158,11 +160,12 @@ struct App { void surface_set_layout_split(uint32_t surface_id, uint32_t sub_surface_id); // Allocate a surface ID for this role - result request_surface(char const *drawing_name); + result api_request_surface(char const *drawing_name); // Activate (i.e. make visible, if allowed!) a surface - char const *activate_surface(char const *drawing_name); - char const *deactivate_surface(char const *drawing_name); + char const *api_activate_surface(char const *drawing_name); + char const *api_deactivate_surface(char const *drawing_name); + char const *api_enddraw(char const *drawing_name); // Events from the compositor we are interested in void surface_created(uint32_t surface_id); @@ -180,7 +183,7 @@ struct App { void activate(int id); void deactivate(int id); - bool can_split(int new_id); + bool can_split(struct LayoutState const &state, int new_id); }; } // namespace wm