From 119cfaff79ca4f89467e9fac9888b1bc6b9143af Mon Sep 17 00:00:00 2001 From: Emre Ucan Date: Mon, 6 Jul 2015 09:02:18 +0200 Subject: ilmControl: set original dimensions at configuration event. It is wrong to set it at source_rectangle event. Original dimensions are dependent on the wayland buffer of the surface, and it can be modified from the client. The compositor sends a configured event when the buffer is modified. Therefore, we should also modify the original dimensions at configuration event. Signed-off-by: Emre Ucan --- .../ilmControl/src/ilm_control_wayland_platform.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'ivi-layermanagement-api') diff --git a/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c b/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c index 97d9633..0bb5a2f 100644 --- a/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c +++ b/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c @@ -519,8 +519,8 @@ controller_surface_listener_configuration(void *data, { struct surface_context *ctx_surf = data; - ctx_surf->prop.sourceWidth = (t_ilm_uint)width; - ctx_surf->prop.sourceHeight = (t_ilm_uint)height; + ctx_surf->prop.origSourceWidth = (t_ilm_uint)width; + ctx_surf->prop.origSourceHeight = (t_ilm_uint)height; } static void @@ -537,12 +537,6 @@ controller_surface_listener_source_rectangle(void *data, ctx_surf->prop.sourceY = (t_ilm_uint)y; ctx_surf->prop.sourceWidth = (t_ilm_uint)width; ctx_surf->prop.sourceHeight = (t_ilm_uint)height; - if (ctx_surf->prop.origSourceWidth == 0) { - ctx_surf->prop.origSourceWidth = (t_ilm_uint)width; - } - if (ctx_surf->prop.origSourceHeight == 0) { - ctx_surf->prop.origSourceHeight = (t_ilm_uint)height; - } if (ctx_surf->notification != NULL) { ctx_surf->notification(ctx_surf->id_surface, -- cgit v1.2.1