wayland: Add method to relate a pad strip to its group
This commit is contained in:
parent
062b696df2
commit
62e4954c96
@ -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);
|
||||
}
|
||||
|
@ -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,
|
||||
|
Loading…
Reference in New Issue
Block a user