Replace remote Registry().execute(event) next/previous with Qt signal

This commit is contained in:
Ken Roberts 2015-01-06 14:37:18 -08:00
parent 9461f334ce
commit a4efccb00b
2 changed files with 4 additions and 1 deletions

View File

@ -338,6 +338,8 @@ class ServiceManager(OpenLPMixin, RegistryMixin, QtGui.QWidget, Ui_ServiceManage
self.setup_ui(self)
# Need to use event as called across threads and UI is updated
QtCore.QObject.connect(self, QtCore.SIGNAL('servicemanager_set_item'), self.on_set_item)
QtCore.QObject.connect(self, QtCore.SIGNAL('servicemanager_next_item'), self.next_item)
QtCore.QObject.connect(self, QtCore.SIGNAL('servicemanager_previous_item'), self.previous_item)
def bootstrap_post_set_up(self):
"""

View File

@ -582,7 +582,8 @@ class HttpRouter(RegistryProperties):
return self.do_http_error()
self.service_manager.emit(QtCore.SIGNAL(event), data)
else:
Registry().execute(event)
# Registry().execute(event)
self.service_manager.emit(QtCore.SIGNAL(event))
self.do_json_header()
return json.dumps({'results': {'success': True}}).encode()