Merge lp:~j-corwin/openlp/bug-880169 into lp:openlp

Proposed by Jonathan Corwin
Status: Merged
Approved by: Tim Bentley
Approved revision: 1841
Merged at revision: 1852
Proposed branch: lp:~j-corwin/openlp/bug-880169
Merge into: lp:openlp
Diff against target: 59 lines (+13/-4)
2 files modified
openlp/core/ui/exceptionform.py (+7/-1)
openlp/core/ui/maindisplay.py (+6/-3)
To merge this branch: bzr merge lp:~j-corwin/openlp/bug-880169
Reviewer Review Type Date Requested Status
Tim Bentley Approve
Andreas Preikschat (community) Approve
Review via email: mp+86702@code.launchpad.net

This proposal supersedes a proposal from 2011-12-22.

Description of the change

For bug 774802 the X11BypassWindowManagerHint was added to fix a problem on Unity.
This causes problems elsewhere, so this fix now only adds this flag when the desktop is Unity.

To post a comment you must log in.
Revision history for this message
Andreas Preikschat (googol-deactivatedaccount) :
review: Approve
Revision history for this message
Tim Bentley (trb143) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'openlp/core/ui/exceptionform.py'
2--- openlp/core/ui/exceptionform.py 2011-10-23 17:22:11 +0000
3+++ openlp/core/ui/exceptionform.py 2011-12-22 13:38:48 +0000
4@@ -32,7 +32,7 @@
5 import sqlalchemy
6 import BeautifulSoup
7 from lxml import etree
8-from PyQt4 import Qt, QtCore, QtGui
9+from PyQt4 import Qt, QtCore, QtGui, QtWebKit
10
11 try:
12 from PyQt4.phonon import Phonon
13@@ -77,6 +77,11 @@
14 UNO_VERSION = node.getByName(u'ooSetupVersion')
15 except ImportError:
16 UNO_VERSION = u'-'
17+try:
18+ WEBKIT_VERSION = QtWebKit.qWebKitVersion()
19+except AttributeError:
20+ WEBKIT_VERSION = u'-'
21+
22
23 from openlp.core.lib import translate, SettingsManager
24 from openlp.core.lib.ui import UiStrings
25@@ -111,6 +116,7 @@
26 u'Qt4: %s\n' % Qt.qVersion() + \
27 u'Phonon: %s\n' % PHONON_VERSION + \
28 u'PyQt4: %s\n' % Qt.PYQT_VERSION_STR + \
29+ u'QtWebkit: %s\n' % WEBKIT_VERSION + \
30 u'SQLAlchemy: %s\n' % sqlalchemy.__version__ + \
31 u'SQLAlchemy Migrate: %s\n' % MIGRATE_VERSION + \
32 u'BeautifulSoup: %s\n' % BeautifulSoup.__version__ + \
33
34=== modified file 'openlp/core/ui/maindisplay.py'
35--- openlp/core/ui/maindisplay.py 2011-12-10 14:34:28 +0000
36+++ openlp/core/ui/maindisplay.py 2011-12-22 13:38:48 +0000
37@@ -29,6 +29,7 @@
38 and play multimedia within OpenLP.
39 """
40 import logging
41+import os
42
43 from PyQt4 import QtCore, QtGui, QtWebKit, QtOpenGL
44 from PyQt4.phonon import Phonon
45@@ -120,9 +121,11 @@
46 self.audioPlayer = None
47 self.firstTime = True
48 self.setStyleSheet(u'border: 0px; margin: 0px; padding: 0px;')
49- self.setWindowFlags(QtCore.Qt.FramelessWindowHint | QtCore.Qt.Tool |
50- QtCore.Qt.WindowStaysOnTopHint |
51- QtCore.Qt.X11BypassWindowManagerHint)
52+ windowFlags = QtCore.Qt.FramelessWindowHint | QtCore.Qt.Tool | \
53+ QtCore.Qt.WindowStaysOnTopHint
54+ if os.environ.get(u'XDG_CURRENT_DESKTOP') == u'Unity':
55+ windowFlags = windowFlags | QtCore.Qt.X11BypassWindowManagerHint
56+ self.setWindowFlags(windowFlags)
57 self.setAttribute(QtCore.Qt.WA_DeleteOnClose)
58 if self.isLive:
59 QtCore.QObject.connect(Receiver.get_receiver(),