diff options
author | Aineopintojen-harjoitustyo-Algoritmit-j <github-hy-tiralabra@v.hix.fi> | 2024-02-05 09:52:02 +0200 |
---|---|---|
committer | Aineopintojen-harjoitustyo-Algoritmit-j <github-hy-tiralabra@v.hix.fi> | 2024-02-05 09:52:02 +0200 |
commit | f2a233474409eb0f39fd5e4906bafb92eebe93d4 (patch) | |
tree | 21e1b573d57b39739e378e1753e7a116657896b9 /tui | |
parent | 282c0fc9f8bb9f9ef45db0d2227b2d31f36620d3 (diff) |
Fixing delay testing not to rely on actual time elapsed.
Diffstat (limited to 'tui')
-rw-r--r-- | tui/tui.py | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -1,6 +1,7 @@ """ tui/tui.py - runko käyttöliittymälle """ # pylint: disable = multiple-imports -from time import sleep +#from time import sleep +import time from .static import Action from .kbd import Kbd, NoKbd from .ansi_draw import AnsiDraw, SuppressDraw @@ -60,7 +61,7 @@ class Tui(): if action != Action.NOOP: if self.delay: self.draw.matrix(matrix, x, y) - sleep(self.delay/100) + time.sleep(self.delay/100) return Action.OPEN if action==Action.SAFE else action, x, y |