diff --git a/src/wayland/meta-wayland-tablet-pad-strip.c b/src/wayland/meta-wayland-tablet-pad-strip.c index f060f87ad..09f1e1711 100644 --- a/src/wayland/meta-wayland-tablet-pad-strip.c +++ b/src/wayland/meta-wayland-tablet-pad-strip.c @@ -33,6 +33,7 @@ #include "meta-surface-actor-wayland.h" #include "meta-wayland-private.h" #include "meta-wayland-tablet-pad.h" +#include "meta-wayland-tablet-pad-group.h" #include "meta-wayland-tablet-pad-strip.h" static void @@ -192,3 +193,14 @@ meta_wayland_tablet_pad_strip_sync_focus (MetaWaylandTabletPadStrip *strip) wl_resource_get_client (strip->pad->focus_surface->resource)); } } + +void +meta_wayland_tablet_pad_strip_set_group (MetaWaylandTabletPadStrip *strip, + MetaWaylandTabletPadGroup *group) +{ + /* Group is static, can only be set once */ + g_assert (strip->group == NULL); + + strip->group = group; + group->strips = g_list_append (group->strips, strip); +} diff --git a/src/wayland/meta-wayland-tablet-pad-strip.h b/src/wayland/meta-wayland-tablet-pad-strip.h index 1f37828d5..e4bd90e10 100644 --- a/src/wayland/meta-wayland-tablet-pad-strip.h +++ b/src/wayland/meta-wayland-tablet-pad-strip.h @@ -32,6 +32,7 @@ struct _MetaWaylandTabletPadStrip { MetaWaylandTabletPad *pad; + MetaWaylandTabletPadGroup *group; struct wl_list resource_list; struct wl_list focus_resource_list; @@ -42,6 +43,9 @@ struct _MetaWaylandTabletPadStrip MetaWaylandTabletPadStrip * meta_wayland_tablet_pad_strip_new (MetaWaylandTabletPad *pad); void meta_wayland_tablet_pad_strip_free (MetaWaylandTabletPadStrip *strip); +void meta_wayland_tablet_pad_strip_set_group (MetaWaylandTabletPadStrip *strip, + MetaWaylandTabletPadGroup *group); + struct wl_resource * meta_wayland_tablet_pad_strip_create_new_resource (MetaWaylandTabletPadStrip *strip, struct wl_client *client,