Add GetWinParent() for debugging.

SVN revision: 9597
This commit is contained in:
Kim Woelders 2004-04-04 21:30:59 +00:00
parent e9ca2698dd
commit b215aca4ac
2 changed files with 15 additions and 0 deletions

View File

@ -2687,6 +2687,7 @@ void UngrabX(void);
void GetWinXY(Window win, int *x, int *y);
void GetWinWH(Window win, unsigned int *w, unsigned int *h);
int GetWinDepth(Window win);
Window GetWinParent(Window win);
int WinExists(Window win);
Window WindowAtXY_0(Window base, int bx, int by, int x, int y);
Window WindowAtXY(int x, int y);

14
src/x.c
View File

@ -742,6 +742,20 @@ GetWinXY(Window win, int *x, int *y)
EDBUG_RETURN_;
}
Window
GetWinParent(Window win)
{
EXID *xid;
EDBUG(7, "GetWinParent");
xid = FindXID(win);
if (xid)
return xid->parent;
EDBUG_RETURN(0);
}
void
GetWinWH(Window win, unsigned int *w, unsigned int *h)
{