diff options
Diffstat (limited to 'xorg-server/present')
-rw-r--r-- | xorg-server/present/makefile | 10 | ||||
-rw-r--r-- | xorg-server/present/present.c | 4 | ||||
-rw-r--r-- | xorg-server/present/present_event.c | 83 | ||||
-rw-r--r-- | xorg-server/present/present_fake.c | 4 | ||||
-rw-r--r-- | xorg-server/present/present_fence.c | 4 | ||||
-rw-r--r-- | xorg-server/present/present_notify.c | 4 | ||||
-rw-r--r-- | xorg-server/present/present_request.c | 29 | ||||
-rw-r--r-- | xorg-server/present/present_screen.c | 4 |
8 files changed, 74 insertions, 68 deletions
diff --git a/xorg-server/present/makefile b/xorg-server/present/makefile new file mode 100644 index 000000000..b56430a65 --- /dev/null +++ b/xorg-server/present/makefile @@ -0,0 +1,10 @@ +CSRCS = \ + present.c \ + present_event.c \ + present_fake.c \ + present_fence.c \ + present_notify.c \ + present_request.c \ + present_screen.c + +LIBRARY=libpresent diff --git a/xorg-server/present/present.c b/xorg-server/present/present.c index f9eef6b26..1bd528b23 100644 --- a/xorg-server/present/present.c +++ b/xorg-server/present/present.c @@ -20,8 +20,8 @@ * OF THIS SOFTWARE. */ -#ifdef HAVE_XORG_CONFIG_H -#include <xorg-config.h> +#ifdef HAVE_DIX_CONFIG_H +#include <dix-config.h> #endif #include "present_priv.h" diff --git a/xorg-server/present/present_event.c b/xorg-server/present/present_event.c index a8f7176eb..9015c9371 100644 --- a/xorg-server/present/present_event.c +++ b/xorg-server/present/present_event.c @@ -20,8 +20,8 @@ * OF THIS SOFTWARE. */ -#ifdef HAVE_XORG_CONFIG_H -#include <xorg-config.h> +#ifdef HAVE_DIX_CONFIG_H +#include <dix-config.h> #endif #include "present_priv.h" @@ -109,24 +109,23 @@ present_send_config_notify(WindowPtr window, int x, int y, int w, int h, int bw, present_window_priv_ptr window_priv = present_window_priv(window); if (window_priv) { - xPresentConfigureNotify cn = { - .type = GenericEvent, - .extension = present_request, - .length = (sizeof(xPresentConfigureNotify) - 32) >> 2, - .evtype = PresentConfigureNotify, - .eid = 0, - .window = window->drawable.id, - .x = x, - .y = y, - .width = w, - .height = h, - .off_x = 0, - .off_y = 0, - .pixmap_width = w, - .pixmap_height = h, - .pixmap_flags = 0 - }; present_event_ptr event; + xPresentConfigureNotify cn; + cn.type = GenericEvent; + cn.extension = present_request; + cn.length = (sizeof(xPresentConfigureNotify) - 32) >> 2; + cn.evtype = PresentConfigureNotify; + cn.eid = 0; + cn.window = window->drawable.id; + cn.x = x; + cn.y = y; + cn.width = w; + cn.height = h; + cn.off_x = 0; + cn.off_y = 0; + cn.pixmap_width = w; + cn.pixmap_height = h; + cn.pixmap_flags = 0; for (event = window_priv->events; event; event = event->next) { if (event->mask & (1 << PresentConfigureNotify)) { @@ -143,20 +142,19 @@ present_send_complete_notify(WindowPtr window, CARD8 kind, CARD8 mode, CARD32 se present_window_priv_ptr window_priv = present_window_priv(window); if (window_priv) { - xPresentCompleteNotify cn = { - .type = GenericEvent, - .extension = present_request, - .length = (sizeof(xPresentCompleteNotify) - 32) >> 2, - .evtype = PresentCompleteNotify, - .kind = kind, - .mode = mode, - .eid = 0, - .window = window->drawable.id, - .serial = serial, - .ust = ust, - .msc = msc, - }; present_event_ptr event; + xPresentCompleteNotify cn; + cn.type = GenericEvent; + cn.extension = present_request; + cn.length = (sizeof(xPresentCompleteNotify) - 32) >> 2; + cn.evtype = PresentCompleteNotify; + cn.kind = kind; + cn.mode = mode; + cn.eid = 0; + cn.window = window->drawable.id; + cn.serial = serial; + cn.ust = ust; + cn.msc = msc; for (event = window_priv->events; event; event = event->next) { if (event->mask & PresentCompleteNotifyMask) { @@ -173,18 +171,17 @@ present_send_idle_notify(WindowPtr window, CARD32 serial, PixmapPtr pixmap, stru present_window_priv_ptr window_priv = present_window_priv(window); if (window_priv) { - xPresentIdleNotify in = { - .type = GenericEvent, - .extension = present_request, - .length = (sizeof(xPresentIdleNotify) - 32) >> 2, - .evtype = PresentIdleNotify, - .eid = 0, - .window = window->drawable.id, - .serial = serial, - .pixmap = pixmap->drawable.id, - .idle_fence = present_fence_id(idle_fence) - }; present_event_ptr event; + xPresentIdleNotify in; + in.type = GenericEvent; + in.extension = present_request; + in.length = (sizeof(xPresentIdleNotify) - 32) >> 2; + in.evtype = PresentIdleNotify; + in.eid = 0; + in.window = window->drawable.id; + in.serial = serial; + in.pixmap = pixmap->drawable.id; + in.idle_fence = present_fence_id(idle_fence); for (event = window_priv->events; event; event = event->next) { if (event->mask & PresentIdleNotifyMask) { diff --git a/xorg-server/present/present_fake.c b/xorg-server/present/present_fake.c index e550e98f8..7926f7a4c 100644 --- a/xorg-server/present/present_fake.c +++ b/xorg-server/present/present_fake.c @@ -20,8 +20,8 @@ * OF THIS SOFTWARE. */ -#ifdef HAVE_XORG_CONFIG_H -#include <xorg-config.h> +#ifdef HAVE_DIX_CONFIG_H +#include <dix-config.h> #endif #include "present_priv.h" diff --git a/xorg-server/present/present_fence.c b/xorg-server/present/present_fence.c index e09657d31..8be32e1a7 100644 --- a/xorg-server/present/present_fence.c +++ b/xorg-server/present/present_fence.c @@ -20,8 +20,8 @@ * OF THIS SOFTWARE. */ -#ifdef HAVE_XORG_CONFIG_H -#include <xorg-config.h> +#ifdef HAVE_DIX_CONFIG_H +#include <dix-config.h> #endif #include "present_priv.h" diff --git a/xorg-server/present/present_notify.c b/xorg-server/present/present_notify.c index e272e08dc..fe8a57117 100644 --- a/xorg-server/present/present_notify.c +++ b/xorg-server/present/present_notify.c @@ -20,8 +20,8 @@ * OF THIS SOFTWARE. */ -#ifdef HAVE_XORG_CONFIG_H -#include <xorg-config.h> +#ifdef HAVE_DIX_CONFIG_H +#include <dix-config.h> #endif #include "present_priv.h" diff --git a/xorg-server/present/present_request.c b/xorg-server/present/present_request.c index 095fa2daf..cd2d334ff 100644 --- a/xorg-server/present/present_request.c +++ b/xorg-server/present/present_request.c @@ -20,8 +20,8 @@ * OF THIS SOFTWARE. */ -#ifdef HAVE_XORG_CONFIG_H -#include <xorg-config.h> +#ifdef HAVE_DIX_CONFIG_H +#include <dix-config.h> #endif #include "present_priv.h" @@ -30,14 +30,14 @@ static int proc_present_query_version(ClientPtr client) { + xPresentQueryVersionReply rep; REQUEST(xPresentQueryVersionReq); - xPresentQueryVersionReply rep = { - .type = X_Reply, - .sequenceNumber = client->sequence, - .length = 0, - .majorVersion = PRESENT_MAJOR, - .minorVersion = PRESENT_MINOR - }; + rep.type = X_Reply; + rep.sequenceNumber = client->sequence; + rep.length = 0; + rep.majorVersion = PRESENT_MAJOR; + rep.minorVersion = PRESENT_MINOR; + REQUEST_SIZE_MATCH(xPresentQueryVersionReq); (void) stuff; @@ -199,15 +199,14 @@ proc_present_select_input (ClientPtr client) static int proc_present_query_capabilities (ClientPtr client) { - REQUEST(xPresentQueryCapabilitiesReq); - xPresentQueryCapabilitiesReply rep = { - .type = X_Reply, - .sequenceNumber = client->sequence, - .length = 0, - }; WindowPtr window; RRCrtcPtr crtc = NULL; int r; + xPresentQueryCapabilitiesReply rep; + REQUEST(xPresentQueryCapabilitiesReq); + rep.type = X_Reply; + rep.sequenceNumber = client->sequence; + rep.length = 0; r = dixLookupWindow(&window, stuff->target, client, DixGetAttrAccess); switch (r) { diff --git a/xorg-server/present/present_screen.c b/xorg-server/present/present_screen.c index 2702cd6ca..6df0c1d99 100644 --- a/xorg-server/present/present_screen.c +++ b/xorg-server/present/present_screen.c @@ -20,8 +20,8 @@ * OF THIS SOFTWARE. */ -#ifdef HAVE_XORG_CONFIG_H -#include <xorg-config.h> +#ifdef HAVE_DIX_CONFIG_H +#include <dix-config.h> #endif #include "present_priv.h" |