glx: unify GLX_SGIX_pbuffer aliased declarations
authorEmil Velikov <emil.velikov@collabora.com>
Mon, 5 Dec 2016 19:52:45 +0000 (19:52 +0000)
committerEmil Velikov <emil.l.velikov@gmail.com>
Wed, 18 Jan 2017 16:01:14 +0000 (16:01 +0000)
No point in having an identical code in two places.

Not to mention that the Apple one incorrectly uses GLXDrawable as pbuf
type. This change is both API and ABI safe since the header uses the
correct GLXPbufferSGIX and both types are a typedef of the same
primitive XID.

Cc: Jeremy Huddleston Sequoia <jeremyhu@apple.com>
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Jeremy Sequoia <jeremyhu@apple.com>
src/glx/apple/glx_empty.c
src/glx/glx_pbuffer.c

index 1e9593c..33fffb5 100644 (file)
@@ -263,19 +263,3 @@ glXGetFBConfigFromVisualSGIX(Display * dpy, XVisualInfo * visinfo)
    return NULL;
 }
 #endif
-
-
-_X_EXPORT
-GLX_ALIAS_VOID(glXDestroyGLXPbufferSGIX,
-               (Display * dpy, GLXDrawable pbuf),
-               (dpy, pbuf), glXDestroyPbuffer)
-
-     _X_EXPORT GLX_ALIAS_VOID(glXSelectEventSGIX,
-                           (Display * dpy, GLXDrawable drawable,
-                            unsigned long mask), (dpy, drawable, mask),
-                           glXSelectEvent)
-
-     _X_EXPORT GLX_ALIAS_VOID(glXGetSelectedEventSGIX,
-                           (Display * dpy, GLXDrawable drawable,
-                            unsigned long *mask), (dpy, drawable, mask),
-                           glXGetSelectedEvent)
index 24c073c..0c15d2a 100644 (file)
@@ -992,7 +992,6 @@ glXDestroyWindow(Display * dpy, GLXWindow win)
 #endif
 }
 
-#ifndef GLX_USE_APPLEGL
 _GLX_PUBLIC
 GLX_ALIAS_VOID(glXDestroyGLXPbufferSGIX,
                (Display * dpy, GLXPbufferSGIX pbuf),
@@ -1008,4 +1007,3 @@ GLX_ALIAS_VOID(glXGetSelectedEventSGIX,
                (Display * dpy, GLXDrawable drawable,
                 unsigned long *mask), (dpy, drawable, mask),
                glXGetSelectedEvent)
-#endif