ivi-shell: fix destroying view that are not shown

Both the core in weston_compositor_build_view_list() with view.link and the
ivi-shell in commit_screen_list() with view.layer_link don't remove the old
views from the list.
As a result, all views that are not currently in the list have old broken
links. Destroying such a view tries to remove the view from these lists and
will access the old, invalid pointers.

Fix this by unmapping all invisible views before the lists are rebuilt.
This removes the views from the lists and all pointer remain valid.

Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
1 job from ivi-view-destroy in 4 minutes and 37 seconds (queued for 24 seconds)
latest
Status Job ID Name Coverage
  Build
passed #30160
build-native

00:04:37