diff -p -up kdegraphics-3.5.9/kgamma/kcmkgamma/xvidextwrap.cpp.orig kdegraphics-3.5.9/kgamma/kcmkgamma/xvidextwrap.cpp --- kdegraphics-3.5.9/kgamma/kcmkgamma/xvidextwrap.cpp.orig 2008-05-08 14:21:23.000000000 -0300 +++ kdegraphics-3.5.9/kgamma/kcmkgamma/xvidextwrap.cpp 2008-05-09 14:31:39.000000000 -0300 @@ -14,6 +14,9 @@ * (at your option) any later version. * * * ***************************************************************************/ + +#include <qwindowdefs.h> + #include <X11/Xos.h> #include <X11/Xlib.h> #include <X11/Xutil.h> @@ -44,7 +47,8 @@ using namespace std; XVidExtWrap::XVidExtWrap(bool* OK, const char* displayname) { - if ((dpy = XOpenDisplay(displayname))) { + dpy = qt_xdisplay(); + if (dpy) { screen = DefaultScreen(dpy); setGammaLimits(0.1, 10.0); *OK = true; @@ -56,7 +60,7 @@ XVidExtWrap::XVidExtWrap(bool* OK, const } XVidExtWrap::~XVidExtWrap() { - if (dpy) XCloseDisplay(dpy); + } int XVidExtWrap::_DefaultScreen() {