Branch: master

c2692e04 2014-04-20 16:02:24 Timothy Pearson
Properly initialize ARGB mode in libtdescreensaver
This resolves an unreported bug whereby many screensavers do not appear when using a compositor
M libtdescreensaver/main.cpp
diff --git a/libtdescreensaver/main.cpp b/libtdescreensaver/main.cpp
index 073d784..2260f25 100644
--- a/libtdescreensaver/main.cpp
+++ b/libtdescreensaver/main.cpp
@@ -34,6 +34,8 @@
 #include "tdescreensaver.h"
 #include "tdescreensaver_vroot.h"
 
+bool argb_visual = FALSE;
+
 extern "C"
 {
     extern const char *kss_applicationName;
@@ -98,7 +100,12 @@
 
     TDECmdLineArgs::addCmdLineOptions(options);
 
+#ifdef HAVE_XCOMPOSITE
+    TDEApplication app(TDEApplication::openX11RGBADisplay());
+    argb_visual = app.isX11CompositionAvailable();
+#else
     TDEApplication app;
+#endif
 
     TDECrash::setCrashHandler( crashHandler );
     TDEGlobal::locale()->insertCatalogue("klock");