This repository has been archived by the owner on Nov 1, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 341
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1493 from emersion/primary-selection-v1
primary-selection-v1: copy from gtk-primary-selection
- Loading branch information
Showing
8 changed files
with
561 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
/* | ||
* This an unstable interface of wlroots. No guarantees are made regarding the | ||
* future consistency of this API. | ||
*/ | ||
#ifndef WLR_USE_UNSTABLE | ||
#error "Add -DWLR_USE_UNSTABLE to enable unstable wlroots features" | ||
#endif | ||
|
||
#ifndef WLR_TYPES_WLR_PRIMARY_SELECTION_V1_H | ||
#define WLR_TYPES_WLR_PRIMARY_SELECTION_V1_H | ||
|
||
#include <wayland-server.h> | ||
#include <wlr/types/wlr_seat.h> | ||
|
||
struct wlr_primary_selection_v1_device_manager { | ||
struct wl_global *global; | ||
struct wl_list resources; // wl_resource_get_link | ||
struct wl_list devices; // wlr_primary_selection_v1_device::link | ||
|
||
struct wl_listener display_destroy; | ||
|
||
struct { | ||
struct wl_signal destroy; | ||
} events; | ||
|
||
void *data; | ||
}; | ||
|
||
/** | ||
* A device is a per-seat object used to set and get the current selection. | ||
*/ | ||
struct wlr_primary_selection_v1_device { | ||
struct wlr_primary_selection_v1_device_manager *manager; | ||
struct wlr_seat *seat; | ||
struct wl_list link; // wlr_primary_selection_v1_device_manager::devices | ||
struct wl_list resources; // wl_resource_get_link | ||
|
||
struct wl_list offers; // wl_resource_get_link | ||
|
||
struct wl_listener seat_destroy; | ||
struct wl_listener seat_focus_change; | ||
struct wl_listener seat_set_primary_selection; | ||
|
||
void *data; | ||
}; | ||
|
||
struct wlr_primary_selection_v1_device_manager * | ||
wlr_primary_selection_v1_device_manager_create(struct wl_display *display); | ||
void wlr_primary_selection_v1_device_manager_destroy( | ||
struct wlr_primary_selection_v1_device_manager *manager); | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.