xkb: Don't call exit on failure in weston_compositor_xkb_init()
[profile/ivi/weston.git] / src / compositor.h
index 4c61db7..c7c583e 100644 (file)
 #include "../shared/config-parser.h"
 #include "weston-egl-ext.h"
 
+#define ARRAY_LENGTH(a) (sizeof (a) / sizeof (a)[0])
+
+#define container_of(ptr, type, member) ({                             \
+       const __typeof__( ((type *)0)->member ) *__mptr = (ptr);        \
+       (type *)( (char *)__mptr - offsetof(type,member) );})
 
 struct weston_transform {
        struct weston_matrix matrix;
@@ -265,6 +270,7 @@ struct weston_layer {
 
 struct weston_plane {
        pixman_region32_t damage;
+       pixman_region32_t opaque;
        int32_t x, y;
 };
 
@@ -716,7 +722,7 @@ void
 weston_seat_init(struct weston_seat *seat, struct weston_compositor *ec);
 void
 weston_seat_init_pointer(struct weston_seat *seat);
-void
+int
 weston_seat_init_keyboard(struct weston_seat *seat, struct xkb_keymap *keymap);
 void
 weston_seat_init_touch(struct weston_seat *seat);