From d16cd74129fa95d50533ca6e76fe2495dd7ba429 Mon Sep 17 00:00:00 2001 From: "Enrico Weigelt, metux IT consult" Date: Thu, 4 Apr 2024 17:49:02 +0200 Subject: [PATCH] xkb: unexport DDX entry points These functions are entry points of the DDX (or stubs thereof), not supposed to be called by any drivers, so no need to keep them exported. Signed-off-by: Enrico Weigelt, metux IT consult --- hw/xfree86/xkb/xkbKillSrv.c | 6 ++++-- hw/xfree86/xkb/xkbPrivate.c | 5 +++-- hw/xfree86/xkb/xkbVT.c | 6 ++++-- include/xkbsrv.h | 15 --------------- xkb/ddxKillSrv.c | 4 +++- xkb/ddxPrivate.c | 4 +++- xkb/ddxVT.c | 4 +++- xkb/xkbsrv_priv.h | 5 +++++ 8 files changed, 25 insertions(+), 24 deletions(-) diff --git a/hw/xfree86/xkb/xkbKillSrv.c b/hw/xfree86/xkb/xkbKillSrv.c index d03674a94..26bc93b72 100644 --- a/hw/xfree86/xkb/xkbKillSrv.c +++ b/hw/xfree86/xkb/xkbKillSrv.c @@ -34,11 +34,13 @@ THE USE OR PERFORMANCE OF THIS SOFTWARE. #include #include #include +#include + +#include "xkb/xkbsrv_priv.h" + #include "inputstr.h" #include "scrnintstr.h" #include "windowstr.h" -#include -#include #include "xf86.h" diff --git a/hw/xfree86/xkb/xkbPrivate.c b/hw/xfree86/xkb/xkbPrivate.c index 779fda187..6e4a8d24e 100644 --- a/hw/xfree86/xkb/xkbPrivate.c +++ b/hw/xfree86/xkb/xkbPrivate.c @@ -7,9 +7,10 @@ #include #include -#include "windowstr.h" -#include +#include "xkb/xkbsrv_priv.h" + +#include "windowstr.h" #include "os.h" #include "xf86.h" diff --git a/hw/xfree86/xkb/xkbVT.c b/hw/xfree86/xkb/xkbVT.c index 463ff2362..842ce936f 100644 --- a/hw/xfree86/xkb/xkbVT.c +++ b/hw/xfree86/xkb/xkbVT.c @@ -34,11 +34,13 @@ THE USE OR PERFORMANCE OF THIS SOFTWARE. #include #include #include +#include + +#include "xkb/xkbsrv_priv.h" + #include "inputstr.h" #include "scrnintstr.h" #include "windowstr.h" -#include -#include #include "xf86.h" diff --git a/include/xkbsrv.h b/include/xkbsrv.h index 96ba07c58..6ecad2f72 100644 --- a/include/xkbsrv.h +++ b/include/xkbsrv.h @@ -557,21 +557,6 @@ extern _X_EXPORT void XkbDDXUpdateDeviceIndicators(DeviceIntPtr /* dev */ , CARD32 /* newState */ ); -extern _X_EXPORT int XkbDDXTerminateServer(DeviceIntPtr /* dev */ , - KeyCode /* key */ , - XkbAction * /* act */ - ); - -extern _X_EXPORT int XkbDDXSwitchScreen(DeviceIntPtr /* dev */ , - KeyCode /* key */ , - XkbAction * /* act */ - ); - -extern _X_EXPORT int XkbDDXPrivate(DeviceIntPtr /* dev */ , - KeyCode /* key */ , - XkbAction * /* act */ - ); - extern _X_EXPORT void XkbDisableComputedAutoRepeats(DeviceIntPtr /* pXDev */ , unsigned int /* key */ ); diff --git a/xkb/ddxKillSrv.c b/xkb/ddxKillSrv.c index e4531388c..4aa5448fa 100644 --- a/xkb/ddxKillSrv.c +++ b/xkb/ddxKillSrv.c @@ -30,10 +30,12 @@ THE USE OR PERFORMANCE OF THIS SOFTWARE. #include #include #include + +#include "xkb/xkbsrv_priv.h" + #include "inputstr.h" #include "scrnintstr.h" #include "windowstr.h" -#include int XkbDDXTerminateServer(DeviceIntPtr dev, KeyCode key, XkbAction *act) diff --git a/xkb/ddxPrivate.c b/xkb/ddxPrivate.c index 26faaa563..9ecd23f0b 100644 --- a/xkb/ddxPrivate.c +++ b/xkb/ddxPrivate.c @@ -2,8 +2,10 @@ #include #include + +#include "xkb/xkbsrv_priv.h" + #include "windowstr.h" -#include int XkbDDXPrivate(DeviceIntPtr dev, KeyCode key, XkbAction *act) diff --git a/xkb/ddxVT.c b/xkb/ddxVT.c index 91b690071..9a10d1310 100644 --- a/xkb/ddxVT.c +++ b/xkb/ddxVT.c @@ -30,10 +30,12 @@ THE USE OR PERFORMANCE OF THIS SOFTWARE. #include #include #include + +#include "xkb/xkbsrv_priv.h" + #include "inputstr.h" #include "scrnintstr.h" #include "windowstr.h" -#include int XkbDDXSwitchScreen(DeviceIntPtr dev, KeyCode key, XkbAction *act) diff --git a/xkb/xkbsrv_priv.h b/xkb/xkbsrv_priv.h index 408a62c7c..7814cd322 100644 --- a/xkb/xkbsrv_priv.h +++ b/xkb/xkbsrv_priv.h @@ -132,6 +132,11 @@ void AccessXCancelRepeatKey(XkbSrvInfoPtr xkbi, KeyCode key); void AccessXComputeCurveFactor(XkbSrvInfoPtr xkbi, XkbControlsPtr ctrls); int XkbDDXAccessXBeep(DeviceIntPtr dev, unsigned int what, unsigned int which); +/* DDX entry points - DDX needs to implement these */ +int XkbDDXTerminateServer(DeviceIntPtr dev, KeyCode key, XkbAction *act); +int XkbDDXSwitchScreen(DeviceIntPtr dev, KeyCode key, XkbAction *act); +int XkbDDXPrivate(DeviceIntPtr dev, KeyCode key, XkbAction *act); + /* client resources */ XkbInterestPtr XkbFindClientResource(DevicePtr inDev, ClientPtr client); XkbInterestPtr XkbAddClientResource(DevicePtr inDev, ClientPtr client, XID id);