~thelinuxguy/openlp/bible-improvements

« back to all changes in this revision

Viewing changes to openlp/core/projectors/manager.py

  • Committer: Raoul Snyman
  • Date: 2018-01-07 19:27:26 UTC
  • mfrom: (2780.2.25 better-threading)
  • Revision ID: raoul@snyman.info-20180107192726-12xpdlysqzszxvjx
Major overhaul of how threading in OpenLP works. Rather than messing around with threads yourself, you create a worker object descended from ThreadWorker, implement start() (and stop() if it's a long-running thread), and run it using run_thread().

Changes related to thread API:

- WebSocket was refactored (mostly into the worker)
- HttpServer was refactored a bit
- CheckMediaWorker was refactored a bit
- Version check refactored
- SongSelect search refactored
- New _wait_for_threads() method...

Show diffs side-by-side

added added

removed removed

Lines of Context:
308
308
        self.settings_section = 'projector'
309
309
        self.projectordb = projectordb
310
310
        self.projector_list = []
311
 
        self.pjlink_udp = PJLinkUDP()
312
 
        self.pjlink_udp.projector_list = self.projector_list
 
311
        self.pjlink_udp = PJLinkUDP(self.projector_list)
313
312
        self.source_select_form = None
314
313
 
315
314
    def bootstrap_initialise(self):