summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas K. Hüttel <dilfridge@gentoo.org>2014-05-02 16:07:05 +0000
committerAndreas K. Hüttel <dilfridge@gentoo.org>2014-05-02 16:07:05 +0000
commit352933f4dff2416891f88e979d18a8463af4fa68 (patch)
tree8c924d5f07bebd9313f5b7a42c92387b25892633 /app-office/libreoffice/files
parentNew package (diff)
downloadgentoo-2-352933f4dff2416891f88e979d18a8463af4fa68.tar.gz
gentoo-2-352933f4dff2416891f88e979d18a8463af4fa68.tar.bz2
gentoo-2-352933f4dff2416891f88e979d18a8463af4fa68.zip
Fix the recursive repaint bug again, bug 509390
(Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key EBE6A336BE19039C!)
Diffstat (limited to 'app-office/libreoffice/files')
-rw-r--r--app-office/libreoffice/files/libreoffice-4.2.3.3-kde4-startup.patch71
1 files changed, 71 insertions, 0 deletions
diff --git a/app-office/libreoffice/files/libreoffice-4.2.3.3-kde4-startup.patch b/app-office/libreoffice/files/libreoffice-4.2.3.3-kde4-startup.patch
new file mode 100644
index 000000000000..4f47abe29dd6
--- /dev/null
+++ b/app-office/libreoffice/files/libreoffice-4.2.3.3-kde4-startup.patch
@@ -0,0 +1,71 @@
+From 71f2aff7a56cef4e133abad3c2e447c76c5ee1fe Mon Sep 17 00:00:00 2001
+From: Luboš Luňák <l.lunak@collabora.com>
+Date: Tue, 25 Mar 2014 11:20:16 +0000
+Subject: prevent KDE/Qt from interfering with the session manager
+
+I occassionally get lockups in IceProcessMessages() called from QtCore,
+I'm actually not exactly sure why, as theoretically two connections
+from one app shouldn't be a problem, but since LO does its own
+session handling, there's no need to the KDE/Qt code to be involved,
+so prevent it from connecting to the session manager altogether.
+
+Change-Id: Iebe20d4cb5403e5fea8bd5d8c1f69b62d1c2907b
+---
+diff --git a/vcl/unx/kde4/KDEXLib.cxx b/vcl/unx/kde4/KDEXLib.cxx
+index 820d39a..e4900a7 100644
+--- a/vcl/unx/kde4/KDEXLib.cxx
++++ b/vcl/unx/kde4/KDEXLib.cxx
+@@ -166,8 +166,23 @@ void KDEXLib::Init()
+
+ KCmdLineArgs::init( m_nFakeCmdLineArgs, m_pAppCmdLineArgs, kAboutData );
+
++ // LO does its own session management, so prevent KDE/Qt from interfering
++ // (QApplication::disableSessionManagement(false) wouldn't quite do,
++ // since that still actually connects to the session manager, it just
++ // won't save the application data on session shutdown).
++ char* session_manager = NULL;
++ if( getenv( "SESSION_MANAGER" ) != NULL )
++ {
++ session_manager = strdup( getenv( "SESSION_MANAGER" ));
++ unsetenv( "SESSION_MANAGER" );
++ }
+ m_pApplication = new VCLKDEApplication();
+- kapp->disableSessionManagement();
++ if( session_manager != NULL )
++ {
++ setenv( "SESSION_MANAGER", session_manager, 1 );
++ free( session_manager );
++ }
++
+ KApplication::setQuitOnLastWindowClosed(false);
+
+ #if KDE_HAVE_GLIB
+diff --git a/vcl/unx/kde4/VCLKDEApplication.hxx b/vcl/unx/kde4/VCLKDEApplication.hxx
+index 412ee34..4ce0b2c 100644
+--- a/vcl/unx/kde4/VCLKDEApplication.hxx
++++ b/vcl/unx/kde4/VCLKDEApplication.hxx
+@@ -21,22 +21,14 @@
+
+ #define Region QtXRegion
+
+-#include <QSessionManager>
+-
+ #include <kapplication.h>
+
+ #undef Region
+
+-/* #i59042# override KApplications method for session management
+- * since it will interfere badly with our own.
+- */
+ class VCLKDEApplication : public KApplication
+ {
+ public:
+ VCLKDEApplication();
+-
+- virtual void commitData(QSessionManager&) {};
+-
+ virtual bool x11EventFilter(XEvent* event);
+ };
+
+--
+cgit v0.9.0.2-2-gbebe