Remove dependency on IpcModuleLoader.h

Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@denso.co.jp>
Added Unit Test Suite for IVI LayerManagement API

Signed-off-by: Timo Lotterbach <timo.lotterbach@bmw-carit.de>
Updated IVI-Application protocol

This update updates the ivi application protocol to include
the changes request by wayland community during upstream
integration of IVI-Shell.

Signed-off-by: Timo Lotterbach <timo.lotterbach@bmw-carit.de>
Bugfix: dead lock issue in ilm library. This happens when several client uses ilm library in parallel because the same display connect is used wihin them.

This is also reported in TIZEN IVI.
TIVI-2880 and TIVI-2883

Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Modify initialize process to use application's native display in each ilm library to avoid deak lock to use the same display connection inter application in ilm library.

This is reported in TIZEN IVI as bugs.
TIVI-2880 and TIVI-2883

Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Modify thread's control in ilm_control.

- create sub thread to receive surface notification event only.
- wl_display of sub thread is accessed by sub thread only.
- sub thread uses wl_display_dispatch() instead of
  wl_display_roundtrip() in order to avoid occupying cpu.
- remove lock and unlock macros.

This is reported in TIZEN IVI.
TIVI-2880 and TIVI-2883

Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Remove wl_list_init of layer_list which will be used by ivi_shell

To avoid clearing not related ivi_controller.so layer. E.g.
cursor and software keyboard.

Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Corrected XML file modes: 0755->0644.

Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
removed obsolete code

most of this code was specific to IVI LayerManagement (ILM) implementation
and is not used in other implementations of ILM API.

Signed-off-by: Timo Lotterbach <timo.lotterbach@bmw-carit.de>
refactored unit tests, check all return values

Signed-off-by: Timo Lotterbach <timo.lotterbach@bmw-carit.de>
fixed return value in ilm_surfaceCreate

Signed-off-by: Timo Lotterbach <timo.lotterbach@bmw-carit.de>
stop control thread during shutdown to prevent crashes

unit tests do fast init/destroy cycles, which resulted in control
thread still using resources (e.g. display) that were already destroyed.

Signed-off-by: Timo Lotterbach <timo.lotterbach@bmw-carit.de>
controller destroys mutex on shutdown

Signed-off-by: Timo Lotterbach <timo.lotterbach@bmw-carit.de>
fixed wrong order of layers in ilm_getLayerIDs

Signed-off-by: Timo Lotterbach <timo.lotterbach@bmw-carit.de>
fixed small error logging issue

several functions logged error 'Invalid ... in
controller_surface_listener_destroyed' and not their real name.
This patch uses __FUNCTION__ to generate function names for logging.

Signed-off-by: Timo Lotterbach <timo.lotterbach@bmw-carit.de>
remove ivi_surface from internal state on ilm_surfaceRemove()

Signed-off-by: Timo Lotterbach <timo.lotterbach@bmw-carit.de>
remove ivi_controller_surface on content_removed event

in ILM API, surfaceDestroy(x) will remove all references to this surface
from scene. To achieve same behavior, ivi controllers must release their
corresponding ivi_controller_surfaces on content_removed event.

Signed-off-by: Timo Lotterbach <timo.lotterbach@bmw-carit.de>
Bug fix: weston crash due to missing destruction of surface.

This is also reported in Tizen IVI JIRA, TIVI-3029

Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Bug fix TIVI 3029. Add destroy surface for main_ctx

Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
ilmClient : Add null check of nativehandle to ilm_surfaceCreate

Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>