diff --git a/ivi-shell/ivi-layout-export.h b/ivi-shell/ivi-layout-export.h index a591873a1..154cf8fa0 100644 --- a/ivi-shell/ivi-layout-export.h +++ b/ivi-shell/ivi-layout-export.h @@ -152,6 +152,14 @@ struct ivi_layout_interface { */ int32_t (*commit_changes)(void); + /** + * \brief Rebuild view list without applying any new changes + * + * \return IVI_SUCCEEDED if the method call was successful + * \return IVI_FAILED if the method call was failed + */ + int32_t (*commit_current)(void); + /** * surface controller interface */ diff --git a/ivi-shell/ivi-layout.c b/ivi-shell/ivi-layout.c index bd7a2311f..8d81e23d8 100644 --- a/ivi-shell/ivi-layout.c +++ b/ivi-shell/ivi-layout.c @@ -1823,6 +1823,16 @@ ivi_layout_commit_changes(void) return IVI_SUCCEEDED; } +static int32_t +ivi_layout_commit_current(void) +{ + struct ivi_layout *layout = get_instance(); + build_view_list(layout); + commit_changes(layout); + send_prop(layout); + return IVI_SUCCEEDED; +} + static int32_t ivi_layout_layer_set_transition(struct ivi_layout_layer *ivilayer, enum ivi_layout_transition_type type, @@ -1983,6 +1993,7 @@ ivi_layout_desktop_surface_configure(struct ivi_layout_surface *ivisurf, int32_t width, int32_t height) { struct ivi_layout *layout = get_instance(); + ivisurf->prop.event_mask |= IVI_NOTIFICATION_CONFIGURE; /* emit callback which is set by ivi-layout api user */ wl_signal_emit(&layout->surface_notification.configure_desktop_changed, @@ -2009,6 +2020,7 @@ ivi_layout_surface_configure(struct ivi_layout_surface *ivisurf, int32_t width, int32_t height) { struct ivi_layout *layout = get_instance(); + ivisurf->prop.event_mask |= IVI_NOTIFICATION_CONFIGURE; /* emit callback which is set by ivi-layout api user */ wl_signal_emit(&layout->surface_notification.configure_changed, @@ -2107,6 +2119,7 @@ static struct ivi_layout_interface ivi_layout_interface = { * commit all changes */ .commit_changes = ivi_layout_commit_changes, + .commit_current = ivi_layout_commit_current, /** * surface controller interfaces diff --git a/ivi-shell/ivi-shell.c b/ivi-shell/ivi-shell.c index 3dc7337a6..23a2f204a 100644 --- a/ivi-shell/ivi-shell.c +++ b/ivi-shell/ivi-shell.c @@ -121,8 +121,10 @@ ivi_shell_surface_committed(struct weston_surface *surface, { struct ivi_shell_surface *ivisurf = get_ivi_shell_surface(surface); - if (surface->width == 0 || surface->height == 0) - return; + if (surface->width == 0 || surface->height == 0) { + if (!weston_surface_is_unmapping(surface)) + return; + } if (ivisurf->width != surface->width || ivisurf->height != surface->height) { @@ -574,8 +576,10 @@ desktop_surface_committed(struct weston_desktop_surface *surface, if(!ivisurf) return; - if (weston_surf->width == 0 || weston_surf->height == 0) - return; + if (weston_surf->width == 0 || weston_surf->height == 0) { + if (!weston_surface_is_unmapping(weston_surf)) + return; + } if (ivisurf->width != weston_surf->width || ivisurf->height != weston_surf->height) {