mirror of
https://github.com/gryf/fs-uae-wrapper.git
synced 2025-12-28 17:32:31 +01:00
Make message close method bit more bulletproof
Noe, it it possible to create Message object and perform close() on it, even if show() wasn't called before. It have a bit more sense since it should be harmless for closing possibly non existent message.
This commit is contained in:
@@ -51,9 +51,10 @@ class Message(object):
|
|||||||
|
|
||||||
def close(self):
|
def close(self):
|
||||||
"""Terminate the process with gui"""
|
"""Terminate the process with gui"""
|
||||||
if self._process.is_alive():
|
if self._process:
|
||||||
self._process.terminate()
|
if self._process.is_alive():
|
||||||
self._process.join()
|
self._process.terminate()
|
||||||
|
self._process.join()
|
||||||
|
|
||||||
|
|
||||||
def _spawn(msg):
|
def _spawn(msg):
|
||||||
|
|||||||
Reference in New Issue
Block a user