From 5ae48da58e40f510ff59b3906d8394689010efe4 Mon Sep 17 00:00:00 2001 From: Ken Roberts Date: Tue, 21 Oct 2014 16:45:15 -0700 Subject: [PATCH] Fix missing poll check --- openlp/core/lib/projector/pjlink1.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/openlp/core/lib/projector/pjlink1.py b/openlp/core/lib/projector/pjlink1.py index 9449003cd..21bf9d605 100644 --- a/openlp/core/lib/projector/pjlink1.py +++ b/openlp/core/lib/projector/pjlink1.py @@ -129,6 +129,8 @@ class PJLink1(QTcpSocket): else: # Default is 5 seconds self.socket_timeout = 5000 + # In case we're called from somewhere that only wants information + self.no_poll = 'no_poll' in kwargs self.i_am_running = False self.status_connect = S_NOT_CONNECTED self.last_command = '' @@ -386,7 +388,7 @@ class PJLink1(QTcpSocket): # Initial data we should know about self.send_command(cmd='CLSS', salt=salt) self.waitForReadyRead() - if not self.new_wizard and self.state() == self.ConnectedState: + if (not self.no_poll) and (self.state() == self.ConnectedState): self.timer.setInterval(2000) # Set 2 seconds for initial information self.timer.start()