From 0356a26d9f8a40bda338352f05243cc9789b3f7f Mon Sep 17 00:00:00 2001 From: "Enrico Weigelt, metux IT consult" Date: Fri, 27 Sep 2024 10:16:31 +0200 Subject: [PATCH] xwin: drop wrapping on ScreenRec->RestackWindow() This proc vector is optional (callers check for non-null) and neither fb nor mi set it, so we can just assign our function directly. No need for wrapping. Signed-off-by: Enrico Weigelt, metux IT consult --- hw/xwin/win.h | 1 - hw/xwin/winmultiwindowwindow.c | 8 -------- hw/xwin/winscrinit.c | 1 - 3 files changed, 10 deletions(-) diff --git a/hw/xwin/win.h b/hw/xwin/win.h index 0b5cf120a..ed7561d5c 100644 --- a/hw/xwin/win.h +++ b/hw/xwin/win.h @@ -503,7 +503,6 @@ typedef struct _winPrivScreenRec { PostValidateTreeProcPtr PostValidateTree; ClearToBackgroundProcPtr ClearToBackground; ClipNotifyProcPtr ClipNotify; - RestackWindowProcPtr RestackWindow; ResizeWindowProcPtr ResizeWindow; MoveWindowProcPtr MoveWindow; ModifyPixmapHeaderProcPtr ModifyPixmapHeader; diff --git a/hw/xwin/winmultiwindowwindow.c b/hw/xwin/winmultiwindowwindow.c index 68ead001f..4b431341a 100644 --- a/hw/xwin/winmultiwindowwindow.c +++ b/hw/xwin/winmultiwindowwindow.c @@ -361,19 +361,11 @@ winRestackWindowMultiWindow(WindowPtr pWin, WindowPtr pOldNextSib) HWND hInsertAfter; HWND hWnd = NULL; #endif - ScreenPtr pScreen = pWin->drawable.pScreen; - - winScreenPriv(pScreen); #if ENABLE_DEBUG || ENABLE_DEBUG winTrace("winRestackMultiWindow - %p\n", pWin); #endif - WIN_UNWRAP(RestackWindow); - if (pScreen->RestackWindow) - (*pScreen->RestackWindow) (pWin, pOldNextSib); - WIN_WRAP(RestackWindow, winRestackWindowMultiWindow); - #if 1 /* * Calling winReorderWindowsMultiWindow here means our window manager diff --git a/hw/xwin/winscrinit.c b/hw/xwin/winscrinit.c index bfca9a8c4..6699c8978 100644 --- a/hw/xwin/winscrinit.c +++ b/hw/xwin/winscrinit.c @@ -402,7 +402,6 @@ winFinishScreenInitFB(int i, ScreenPtr pScreen, int argc, char **argv) } /* Save a pointer to each lower-level window procedure */ - WRAP(RestackWindow); WRAP(ResizeWindow); WRAP(MoveWindow); WRAP(ModifyPixmapHeader);