aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/xwin/glx
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/hw/xwin/glx')
-rw-r--r--xorg-server/hw/xwin/glx/indirect.c1
-rw-r--r--xorg-server/hw/xwin/glx/winpriv.c19
2 files changed, 17 insertions, 3 deletions
diff --git a/xorg-server/hw/xwin/glx/indirect.c b/xorg-server/hw/xwin/glx/indirect.c
index 516cb6af0..6dd00c483 100644
--- a/xorg-server/hw/xwin/glx/indirect.c
+++ b/xorg-server/hw/xwin/glx/indirect.c
@@ -875,6 +875,7 @@ glxWinPositionWindow(WindowPtr pWin, int x, int y)
pWin->drawable.width,
pWin->drawable.height,
FALSE);
+ winDebug("Move window %x, %x, %d, %d, %d, %d\n",pWinPriv->hWnd,GetParent(pWinPriv->hWnd), pWin->drawable.x, pWin->drawable.y, pWin->drawable.width, pWin->drawable.height);
}
return result;
}
diff --git a/xorg-server/hw/xwin/glx/winpriv.c b/xorg-server/hw/xwin/glx/winpriv.c
index 6c16c31ae..c689bae08 100644
--- a/xorg-server/hw/xwin/glx/winpriv.c
+++ b/xorg-server/hw/xwin/glx/winpriv.c
@@ -57,6 +57,8 @@ HWND winGetWindowInfo(WindowPtr pWin)
{
if (pWin->parent && pWin->parent->parent)
{
+ int offsetx;
+ int offsety;
int ExtraClass=(pWin->realized)?WS_VISIBLE:0;
HWND hWndParent;
WindowPtr pParent=pWin->parent;
@@ -70,24 +72,35 @@ HWND winGetWindowInfo(WindowPtr pWin)
}
if (!hWndParent)
hWndParent=hwnd;
+ if (pParent)
+ {
+ offsetx=pParent->drawable.x;
+ offsety=pParent->drawable.y;
+ }
+ else
+ {
+ offsetx=0;
+ offsety=0;
+ }
pWinPriv->hWnd=CreateWindowExA(WS_EX_TRANSPARENT,
WIN_GL_WINDOW_CLASS,
"",
WS_CHILD |WS_CLIPSIBLINGS | WS_CLIPCHILDREN | ExtraClass,
- pWin->drawable.x,
- pWin->drawable.y,
+ pWin->drawable.x-offsetx,
+ pWin->drawable.y-offsety,
pWin->drawable.width,
pWin->drawable.height,
hWndParent,
NULL,
GetModuleHandle(NULL),
NULL);
+ winDebug("Window created %x %x %d %d %d %d\n",pWinPriv->hWnd,hWndParent,pWin->drawable.x-offsetx,pWin->drawable.y-offsety,pWin->drawable.width, pWin->drawable.height);
pWinPriv->GlCtxWnd=TRUE;
}
else
{
winCreateWindowsWindow(pWin);
- ErrorF("winGetWindowInfo: forcing window to exist...\n");
+ winDebug("winGetWindowInfo: forcing window to exist...\n");
}
}
if (pWinPriv->hWnd != NULL)