mirror of
https://gitlab.freedesktop.org/wayland/wayland.git
synced 2025-11-03 09:01:42 -05:00
data-device: Don't implement data source through data offer object
The wl_data_source object used to specify the implementation for data offers created for it. This means you need a data offer to retrieve the data from the source, which makes it awkward to use in-process in a compositor. Now we instead have three virtual functions that can be connected to a protocol object or in-process data-sources such as an X server proxy or clipboard.
This commit is contained in:
parent
dff84e5638
commit
68f058ffd3
2 changed files with 39 additions and 22 deletions
|
|
@ -232,7 +232,10 @@ struct wl_data_source {
|
|||
struct wl_resource resource;
|
||||
struct wl_array mime_types;
|
||||
|
||||
const struct wl_data_offer_interface *offer_interface;
|
||||
void (*accept)(struct wl_data_source *source,
|
||||
uint32_t serial, const char *mime_type);
|
||||
void (*send)(struct wl_data_source *source,
|
||||
const char *mime_type, int32_t fd);
|
||||
void (*cancel)(struct wl_data_source *source);
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue