Bool rdpRealizeWindow(WindowPtr pWindow) { ScreenPtr pScreen; rdpWindowRec *priv; Bool rv; LLOGLN(10, ("rdpRealizeWindow:")); priv = GETWINPRIV(pWindow); pScreen = pWindow->drawable.pScreen; pScreen->RealizeWindow = g_rdpScreen.RealizeWindow; rv = pScreen->RealizeWindow(pWindow); pScreen->RealizeWindow = rdpRealizeWindow; if (g_use_rail) { if ((pWindow != g_invalidate_window) && (pWindow->parent != 0)) { if (XR_IS_ROOT(pWindow->parent)) { LLOGLN(10, ("rdpRealizeWindow:")); LLOGLN(10, (" pWindow %p id 0x%x pWindow->parent %p id 0x%x x %d " "y %d width %d height %d", pWindow, (int)(pWindow->drawable.id), pWindow->parent, (int)(pWindow->parent->drawable.id), pWindow->drawable.x, pWindow->drawable.y, pWindow->drawable.width, pWindow->drawable.height)); priv->status = 1; rdpup_create_window(pWindow, priv); } } } return rv; }
Bool rdpRealizeWindow(WindowPtr pWindow) { ScreenPtr pScreen; rdpWindowRec* priv; Bool rv; ErrorF("rdpRealizeWindow:\n"); priv = GETWINPRIV(pWindow); pScreen = pWindow->drawable.pScreen; pScreen->RealizeWindow = g_rdpScreen.RealizeWindow; rv = pScreen->RealizeWindow(pWindow); pScreen->RealizeWindow = rdpRealizeWindow; return rv; }
Bool glWinRealizeWindow(WindowPtr pWin) { /* If this window has GL contexts, tell them to reattach */ Bool result; ScreenPtr pScreen = pWin->drawable.pScreen; glWinScreenRec *screenPriv = &glWinScreens[pScreen->myNum]; __GLXdrawablePrivate *glxPriv; GLWIN_DEBUG_MSG("glWinRealizeWindow\n"); /* Allow the window to be created (RootlessRealizeWindow is inside our wrap) */ pScreen->RealizeWindow = screenPriv->RealizeWindow; result = pScreen->RealizeWindow(pWin); pScreen->RealizeWindow = glWinRealizeWindow; /* Re-attach this window's GL contexts, if any. */ glxPriv = __glXFindDrawablePrivate(pWin->drawable.id); if (glxPriv) { __GLXcontext *gx; __GLcontext *gc; __GLdrawablePrivate *glPriv = &glxPriv->glPriv; GLWIN_DEBUG_MSG("glWinRealizeWindow is GL drawable!\n"); /* GL contexts bound to this window for drawing */ for (gx = glxPriv->drawGlxc; gx != NULL; gx = gx->next) { gc = (__GLcontext *)gx->gc; if (gc->isAttached) unattach(gc); attach(gc, glPriv); } /* GL contexts bound to this window for reading */ for (gx = glxPriv->readGlxc; gx != NULL; gx = gx->next) { gc = (__GLcontext *)gx->gc; if (gc->isAttached) unattach(gc); attach(gc, glPriv); } } return result; }