MCPcopy Create free account
hub / github.com/HelpFreedom/youthub / _loop

Method _loop

tui_player.py:148–161  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

146 self._thread.start()
147
148 def _loop(self):
149 while not self.event.is_set():
150 r, _, _ = select.select([sys.stdin], [], [], 0.1)
151 if not r:
152 continue
153 ch = sys.stdin.read(1)
154 if ch in ("q", "Q", "\x03", "\x04"):
155 self.event.set()
156 return
157 if ch == " ":
158 if self.pause.is_set():
159 self.pause.clear()
160 else:
161 self.pause.set()
162
163 def stop(self):
164 if self._old_termios is not None:

Callers

nothing calls this directly

Calls 1

readMethod · 0.80

Tested by

no test coverage detected