From 356e5c30a8bf03e240f9a79043bcfc25c2f72494 Mon Sep 17 00:00:00 2001 From: tpearson Date: Thu, 11 Aug 2011 03:27:08 +0000 Subject: Fix composite extension auto detection git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1246278 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kdecore/kapplication.cpp | 19 +++++++++++++++++++ kdecore/kapplication.h | 8 +++----- 2 files changed, 22 insertions(+), 5 deletions(-) (limited to 'kdecore') diff --git a/kdecore/kapplication.cpp b/kdecore/kapplication.cpp index 7986079f4..5606b54fa 100644 --- a/kdecore/kapplication.cpp +++ b/kdecore/kapplication.cpp @@ -20,6 +20,10 @@ #include "config.h" +#ifdef HAVE_XCOMPOSITE +#define COMPOSITE +#endif + // #ifdef QTRANSLATOR_H // #error qtranslator.h was already included // #endif // QTRANSLATOR_H @@ -1910,6 +1914,21 @@ KApplication KApplication::KARGBApplicationObject( bool allowStyles ) { } } #else +void KApplication::getX11RGBAInformation(Display *dpy) { +} + +bool KApplication::isCompositionManagerAvailable() { + return false; +} + +bool KApplication::detectCompositionManagerAvailable(bool force_available) { + return false; +} + +Display* KApplication::openX11RGBADisplay() { + return 0; +} + Qt::HANDLE KApplication::getX11RGBAVisual(char *display) { return 0; } diff --git a/kdecore/kapplication.h b/kdecore/kapplication.h index 00a6429da..9558d528e 100644 --- a/kdecore/kapplication.h +++ b/kdecore/kapplication.h @@ -48,8 +48,6 @@ class KSessionManaged; class KStyle; class KURL; -#define COMPOSITE // [FIXME] Autodetect composition support - #define kapp KApplication::kApplication() class KApplicationPrivate; @@ -866,13 +864,14 @@ public: */ TQString checkRecoverFile( const TQString& pFilename, bool& bRecover ) const; -#if defined(Q_WS_X11) && defined(COMPOSITE) +#if defined(Q_WS_X11) /** * @internal * Get the X11 display * @return the X11 Display */ Display *getDisplay() { return display; } +#endif /** * @internal @@ -904,7 +903,6 @@ public: * @return the X11 display handle */ Display *openX11RGBADisplay(); -#endif /** * @internal @@ -1281,7 +1279,7 @@ private: void initUrlActionRestrictions(); bool argb_visual; -#if defined(Q_WS_X11) && defined(COMPOSITE) +#if defined(Q_WS_X11) Qt::HANDLE argb_x11_visual; Qt::HANDLE argb_x11_colormap; #endif -- cgit v1.2.1