glx: Move drawHash to display private

The XIDs are display wide so the natural location of the hash is here.
This way we don't have to lookup in each of the screen hashes.
This commit is contained in:
Kristian Høgsberg
2010-07-19 21:15:50 -04:00
parent 037755122e
commit e3e8196c02
5 changed files with 27 additions and 41 deletions

View File

@@ -202,7 +202,7 @@ CreateDRIDrawable(Display *dpy, const __GLcontextModes *fbconfig,
return;
}
if (__glxHashInsert(psc->drawHash, glxdrawable, pdraw)) {
if (__glxHashInsert(priv->drawHash, glxdrawable, pdraw)) {
(*pdraw->destroyDrawable) (pdraw);
return; /* FIXME: Check what we're supposed to do here... */
}
@@ -223,7 +223,7 @@ DestroyDRIDrawable(Display *dpy, GLXDrawable drawable, int destroy_xdrawable)
if (destroy_xdrawable)
XFreePixmap(psc->dpy, pdraw->xDrawable);
(*pdraw->destroyDrawable) (pdraw);
__glxHashDelete(psc->drawHash, drawable);
__glxHashDelete(priv->drawHash, drawable);
}
}