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