'Add thread to queue'

def add_thread(self, checker, end_callback, source_code, parent):

    parent_id = id(parent)
    thread = AnalysisThread(self, checker, source_code)
    self.end_callbacks[id(thread)] = end_callback
    self.pending_threads.append((thread, parent_id))
    if DEBUG_EDITOR:
        print(('Added    thread    %r    to    queue' % thread), file=STDOUT)
    QTimer.singleShot(50, self.update_queue)
