mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-01-19 09:30:44 +00:00
query the server for the pixmap format rather than trying to guess ourselves
This commit is contained in:
parent
1937e53b3c
commit
33b2e92a85
@ -580,20 +580,15 @@ nsDrawingSurface nsRenderingContextUnix :: CreateDrawingSurface(nsRect *aBounds)
|
||||
}
|
||||
|
||||
#ifdef MITSHM
|
||||
PRUint32 format;
|
||||
|
||||
if (mRenderingSurface->visual->c_class == TrueColor ||
|
||||
mRenderingSurface->visual->c_class == DirectColor)
|
||||
format = ZPixmap;
|
||||
else
|
||||
format = XYPixmap;
|
||||
|
||||
if (mSupportsSharedPixmaps == PR_TRUE) {
|
||||
|
||||
mRenderingSurface->shmImage =
|
||||
::XShmCreateImage(mRenderingSurface->display,
|
||||
mRenderingSurface->visual,
|
||||
depth, format, 0,
|
||||
depth,
|
||||
XShmPixmapFormat(mRenderingSurface->display),
|
||||
0,
|
||||
&(mRenderingSurface->shmInfo),
|
||||
w,h);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user