05d1cc238f65f15bb96a35e6ef8d10533852d779
[AGL/meta-agl.git] / meta-agl-profile-graphical / recipes-graphics / wayland / wayland-ivi-extension / 0004-ivi-ilmcontrol-added-focus-notification.patch
1 diff --git a/ivi-layermanagement-api/ilmCommon/include/ilm_types.h b/ivi-layermanagement-api/ilmCommon/include/ilm_types.h
2 index a88f2b0..12a2017 100644
3 --- a/ivi-layermanagement-api/ilmCommon/include/ilm_types.h
4 +++ b/ivi-layermanagement-api/ilmCommon/include/ilm_types.h
5 @@ -245,6 +245,7 @@ typedef enum
6      ILM_NOTIFICATION_CONTENT_AVAILABLE = ILM_BIT(6),
7      ILM_NOTIFICATION_CONTENT_REMOVED = ILM_BIT(7),
8      ILM_NOTIFICATION_CONFIGURED = ILM_BIT(8),
9 +    ILM_NOTIFICATION_FOCUS = ILM_BIT(9),
10      ILM_NOTIFICATION_ALL = 0xffff
11  } t_ilm_notification_mask;
12  
13 diff --git a/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c b/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c
14 index a912e50..5166839 100644
15 --- a/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c
16 +++ b/ivi-layermanagement-api/ilmControl/src/ilm_control_wayland_platform.c
17 @@ -819,6 +819,12 @@ input_listener_input_focus(void *data,
18              surf_ctx->prop.focus |= device;
19          else
20              surf_ctx->prop.focus &= ~device;
21 +
22 +        if (surf_ctx->notification != NULL) {
23 +            surf_ctx->notification(surf_ctx->id_surface,
24 +                                    &surf_ctx->prop,
25 +                                    ILM_NOTIFICATION_FOCUS);
26 +        }
27      }
28  }
29