From a58fd6f511d906dc284b99ad93c7af0d846c37c1 Mon Sep 17 00:00:00 2001 From: "Enrico Weigelt, metux IT consult" Date: Fri, 23 May 2025 12:23:35 +0200 Subject: [PATCH] (!2007) dix: unexport SendGraphicsExpose() and fix parameter types * not used by any drivers, so no need to keep it exported * fix parameter types to matching the protocol types Signed-off-by: Enrico Weigelt, metux IT consult --- dix/dispatch.c | 2 +- dix/dix_priv.h | 16 ++++++++++++++++ include/dix.h | 6 ------ 3 files changed, 17 insertions(+), 7 deletions(-) diff --git a/dix/dispatch.c b/dix/dispatch.c index da2d01f0c..d54873fb1 100644 --- a/dix/dispatch.c +++ b/dix/dispatch.c @@ -1726,7 +1726,7 @@ ProcClearToBackground(ClientPtr client) /* send GraphicsExpose events, or a NoExpose event, based on the region */ void SendGraphicsExpose(ClientPtr client, RegionPtr pRgn, XID drawable, - int major, int minor) + CARD8 major, CARD16 minor) { if (pRgn && !RegionNil(pRgn)) { xEvent *pEvent; diff --git a/dix/dix_priv.h b/dix/dix_priv.h index d77cd267e..a4e324059 100644 --- a/dix/dix_priv.h +++ b/dix/dix_priv.h @@ -390,4 +390,20 @@ void SendErrorToClient(ClientPtr pClient, BYTE errorCode) _X_ATTRIBUTE_NONNULL_ARG(1); +/* + * @brief send GraphicsExposure events for given region to client + + * Sends a series of GraphicsExposure events spanning the given region to the + * client. If region is empty or NULL, sending NoExpose event instead. + * + + @param pClient the client to send events to + * @param pRegion the region the events are based on + * @param drawable ID of the drawable the events are related to + * @param majorOpcode major opcode of request which caused the expose event + * @param minorOpcode minor opcode of request which caused the expose event + */ +void SendGraphicsExpose(ClientPtr pClient, RegionPtr pRegion, XID drawable, + BYTE majorOpcode, CARD16 minorOpcode) + _X_ATTRIBUTE_NONNULL_ARG(1); + #endif /* _XSERVER_DIX_PRIV_H */ diff --git a/include/dix.h b/include/dix.h index 51b126094..08f4d77a2 100644 --- a/include/dix.h +++ b/include/dix.h @@ -210,12 +210,6 @@ extern _X_EXPORT Bool QueueWorkProc(Bool (*function)(ClientPtr clientUnused, ClientPtr client, void *closure); -extern _X_EXPORT void SendGraphicsExpose(ClientPtr /*client */ , - RegionPtr /*pRgn */ , - XID /*drawable */ , - int /*major */ , - int /*minor */); - /* atom.c */ extern _X_EXPORT Atom MakeAtom(const char * /*string */ ,