注册一个线程,并启动它
(cls, name)
| 328 | |
| 329 | @classmethod |
| 330 | def register(cls, name) -> None: |
| 331 | """ |
| 332 | 注册一个线程,并启动它 |
| 333 | """ |
| 334 | if cls.hasThread(name): |
| 335 | raise RuntimeError("This thread has already been registered.") |
| 336 | thread = QThread() |
| 337 | thread.start() |
| 338 | cls.threads[name] = thread |
| 339 | |
| 340 | @classmethod |
| 341 | def getThread(cls, name) -> Optional[QThread]: |
no test coverage detected