openlp-core team mailing list archive
-
openlp-core team
-
Mailing list archive
-
Message #12842
[Merge] lp:~trb143/openlp/bug-892571 into lp:openlp
Tim Bentley has proposed merging lp:~trb143/openlp/bug-892571 into lp:openlp.
Requested reviews:
OpenLP Core (openlp-core)
Related bugs:
Bug #892571 in OpenLP: "Service Manager Keys do mad things"
https://bugs.launchpad.net/openlp/+bug/892571
For more details, see:
https://code.launchpad.net/~trb143/openlp/bug-892571/+merge/83116
Stop keyboard floods getting the slide controller and service manager out of set.
Key presses are only accepted when the previous updates have happened.
To Test set preview next song to on.
Add 5 songs to service manager
Select the first one.
Press the right arrow key fast.
--
https://code.launchpad.net/~trb143/openlp/bug-892571/+merge/83116
Your team OpenLP Core is requested to review the proposed merge of lp:~trb143/openlp/bug-892571 into lp:openlp.
=== modified file 'openlp/core/ui/slidecontroller.py'
--- openlp/core/ui/slidecontroller.py 2011-10-31 09:14:07 +0000
+++ openlp/core/ui/slidecontroller.py 2011-11-23 06:21:07 +0000
@@ -79,6 +79,7 @@
self.songEdit = False
self.selectedRow = 0
self.serviceItem = None
+ self.accept_keypress = True
self.panel = QtGui.QWidget(parent.controlSplitter)
self.slideList = {}
# Layout for holding panel
@@ -578,12 +579,17 @@
self.display.videoStop()
def servicePrevious(self):
- time.sleep(0.1)
- Receiver.send_message('servicemanager_previous_item')
+ if self.accept_keypress:
+ self.accept_keypress = False
+ Receiver.send_message('servicemanager_previous_item')
+ self.accept_keypress = True
def serviceNext(self):
- time.sleep(0.1)
- Receiver.send_message('servicemanager_next_item')
+ if self.accept_keypress:
+ self.accept_keypress = False
+ Receiver.send_message('servicemanager_next_item')
+ self.accept_keypress = True
+
def screenSizeChanged(self):
"""
@@ -771,7 +777,7 @@
log.debug(u'processManagerItem live = %s' % self.isLive)
self.onStopLoop()
old_item = self.serviceItem
- # take a copy not a link to the servicemeanager copy.
+ # take a copy not a link to the servicemanager copy.
self.serviceItem = copy.copy(serviceItem)
if old_item and self.isLive and old_item.is_capable(
ItemCapabilities.ProvidesOwnDisplay):
Follow ups