Improved spinner

This commit is contained in:
Sven Heidemann 2021-03-10 08:17:52 +01:00
parent f4ca76d844
commit 59206dbc32

View File

@ -20,16 +20,13 @@ class SpinnerThread(threading.Thread):
print('\t', end='')
spinner = self._spinner()
while self._is_spinning:
# self._console.write(next(spinner))
print(next(spinner), end='')
time.sleep(0.1)
# self._console.write('\b')
print('\b', end='')
sys.stdout.flush()
# self._console.write(' ')
print(' ', end='')
print('done', end='')
def stop_spinning(self):
self._is_spinning = False