This patch introduces a hook point for SUBSURFACE_COMMIT_TO_CACHE.
A function given to e_comp_wl_hook_add() with this hook point will be
called when changes of subsurface is committed to cache.
It will give a chance for others to cache its changes by itself.
An implementation of tizen_viewport as an extension of wayland protocol
for tizen will use this hook point for caching its changes in a
future patch.
NOTE:
Modules which listen to this hook event should apply its cached state to
current state first when wl_surface.commit occurs. Yet when there is no
cached state at that moment, it should apply pending state.
COMMIT TO CACHE
pending -> cache
wl_surface.commit
cache ? cache -> current : pending -> current
Change-Id: I35f908881d8ff06a40d90b4d78b381d31b259ef1
{
E_COMP_WL_HOOK_SHELL_SURFACE_READY,
E_COMP_WL_HOOK_SUBSURFACE_CREATE,
+ E_COMP_WL_HOOK_SUBSURFACE_COMMIT_TO_CACHE,
E_COMP_WL_HOOK_BUFFER_CHANGE,
E_COMP_WL_HOOK_CLIENT_REUSE,
E_COMP_WL_HOOK_BUFFER_SIZE_CHANGE,
e_presentation_time_container_feedback_merge(&sdata->cached.presentation_container,
&cdata->pending.presentation_container);
+ e_comp_wl_hook_call(E_COMP_WL_HOOK_SUBSURFACE_COMMIT_TO_CACHE, ec);
+
sdata->cached.has_data = EINA_TRUE;
}