mirror of https://github.com/hak5/ToorChat.git
Grahpical updates
parent
9cdd51111a
commit
12959f2641
|
@ -58,7 +58,7 @@ class Visualizer():
|
||||||
self.__add_message_to_screen__()
|
self.__add_message_to_screen__()
|
||||||
entry = self.screen.getch()
|
entry = self.screen.getch()
|
||||||
if entry == curses.KEY_RESIZE:
|
if entry == curses.KEY_RESIZE:
|
||||||
self.__draw_frame__()
|
self.__draw_frame__(False)
|
||||||
if entry == ord('s'):
|
if entry == ord('s'):
|
||||||
self.screen.nodelay(0)
|
self.screen.nodelay(0)
|
||||||
user_input = self.screen.getstr(1, 1, 60)
|
user_input = self.screen.getstr(1, 1, 60)
|
||||||
|
@ -86,8 +86,10 @@ class Visualizer():
|
||||||
self.message_queue.pop()
|
self.message_queue.pop()
|
||||||
if self.last_message_index > self.screen_max_y-5:
|
if self.last_message_index > self.screen_max_y-5:
|
||||||
self.last_message_index = 0
|
self.last_message_index = 0
|
||||||
|
self.__draw_frame__()
|
||||||
|
|
||||||
def __draw_frame__(self):
|
def __draw_frame__(self, clear = True):
|
||||||
|
if clear:
|
||||||
self.screen.clear()
|
self.screen.clear()
|
||||||
self.screen.border(0)
|
self.screen.border(0)
|
||||||
self.screen.addstr(2,1,"_"*(self.screen_max_x-2))
|
self.screen.addstr(2,1,"_"*(self.screen_max_x-2))
|
||||||
|
|
Loading…
Reference in New Issue