1 /* 2 * Copyright © 2008-2011 Kristian Høgsberg 3 * Copyright © 2011 Intel Corporation 4 * Copyright © 2013 Jason Ekstrand 5 * 6 * Permission is hereby granted, free of charge, to any person obtaining 7 * a copy of this software and associated documentation files (the 8 * "Software"), to deal in the Software without restriction, including 9 * without limitation the rights to use, copy, modify, merge, publish, 10 * distribute, sublicense, and/or sell copies of the Software, and to 11 * permit persons to whom the Software is furnished to do so, subject to 12 * the following conditions: 13 * 14 * The above copyright notice and this permission notice (including the 15 * next paragraph) shall be included in all copies or substantial 16 * portions of the Software. 17 * 18 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 20 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS 22 * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN 23 * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 24 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 25 * SOFTWARE. 26 */ 27 28 #ifndef WAYLAND_SERVER_PRIVATE_H 29 #define WAYLAND_SERVER_PRIVATE_H 30 31 #include "wayland-server-core.h" 32 33 struct wl_priv_signal { 34 struct wl_list listener_list; 35 struct wl_list emit_list; 36 }; 37 38 void 39 wl_priv_signal_init(struct wl_priv_signal *signal); 40 41 void 42 wl_priv_signal_add(struct wl_priv_signal *signal, struct wl_listener *listener); 43 44 struct wl_listener * 45 wl_priv_signal_get(struct wl_priv_signal *signal, wl_notify_func_t notify); 46 47 void 48 wl_priv_signal_emit(struct wl_priv_signal *signal, void *data); 49 50 void 51 wl_priv_signal_final_emit(struct wl_priv_signal *signal, void *data); 52 53 #endif 54