From 9e49ceb12985697fbfc0b2fa8f86143b29cc837b Mon Sep 17 00:00:00 2001 From: Ivan Molodetskikh Date: Fri, 1 Feb 2019 12:49:46 +0300 Subject: data-control: add primary selection support data-control: separate out a data_offer struct This is a prerequisite to adding primary selection support. data-control: separate out data_control_source This is a prerequisite to adding primary selection support, since that doesn't use wlr_data_source, but rather wlr_primary_selection_source. Update the data-control protocol data-control: add primary selection support Merge create_offer and create_primary_offer Extract code into data_control_source_destroy() Fix pointer style Move resource neutralization to destructor Store wl_resource in the data_offer Extract data_offer destruction into a function --- include/wlr/types/wlr_data_control_v1.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include') diff --git a/include/wlr/types/wlr_data_control_v1.h b/include/wlr/types/wlr_data_control_v1.h index 7d336344..32d169b4 100644 --- a/include/wlr/types/wlr_data_control_v1.h +++ b/include/wlr/types/wlr_data_control_v1.h @@ -32,9 +32,11 @@ struct wlr_data_control_device_v1 { struct wlr_seat *seat; struct wl_resource *selection_offer_resource; // current selection offer + struct wl_resource *primary_selection_offer_resource; // current primary selection offer struct wl_listener seat_destroy; struct wl_listener seat_set_selection; + struct wl_listener seat_set_primary_selection; }; struct wlr_data_control_manager_v1 *wlr_data_control_manager_v1_create( -- cgit v1.2.3