forked from openlp/openlp
clean up
This commit is contained in:
parent
2a0f3b272a
commit
1e0ef1ecb8
@ -97,7 +97,7 @@ class OpenLP(QtGui.QApplication):
|
||||
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||
QtCore.SIGNAL(u'cursor_normal'), self.setNormalCursor)
|
||||
# Decide how many screens we have and their size
|
||||
screens = ScreenList.get_instance(self.desktop())
|
||||
screens = ScreenList(self.desktop())
|
||||
# First time checks in settings
|
||||
has_run_wizard = QtCore.QSettings().value(
|
||||
u'general/has run wizard', QtCore.QVariant(False)).toBool()
|
||||
|
@ -46,9 +46,7 @@ class ScreenList(object):
|
||||
instance = None
|
||||
|
||||
@staticmethod
|
||||
def get_instance(desktop=None):
|
||||
if desktop is not None and ScreenList.instance is None:
|
||||
ScreenList.instance = ScreenList(desktop)
|
||||
def get_instance():
|
||||
return ScreenList.instance
|
||||
|
||||
def __init__(self, desktop):
|
||||
@ -58,6 +56,7 @@ class ScreenList(object):
|
||||
``desktop``
|
||||
A ``QDesktopWidget`` object.
|
||||
"""
|
||||
ScreenList.instance = self
|
||||
self.desktop = desktop
|
||||
self.preview = None
|
||||
self.current = None
|
||||
|
Loading…
Reference in New Issue
Block a user