mirror of
https://github.com/nicolargo/glances.git
synced 2024-12-27 19:25:27 +03:00
Disable popup filter on Windows OS
This commit is contained in:
parent
9f551a5637
commit
3f2654d9d5
@ -20,7 +20,7 @@
|
||||
"""Init the Glances software."""
|
||||
|
||||
__appname__ = 'glances'
|
||||
__version__ = '2.1_RC7'
|
||||
__version__ = '2.1_RC8'
|
||||
__author__ = 'Nicolas Hennion <nicolas@nicolargo.com>'
|
||||
__license__ = 'LGPL'
|
||||
|
||||
|
@ -545,7 +545,7 @@ class GlancesCurses(object):
|
||||
popup.addnstr(2 + y, 2, m, len(m))
|
||||
y += 1
|
||||
|
||||
if is_input:
|
||||
if is_input and not is_windows:
|
||||
# Create a subwindow for the text field
|
||||
subpop = popup.derwin(1, input_size, 2, 2 + len(m))
|
||||
subpop.attron(self.__colors_list['FILTER'])
|
||||
@ -717,15 +717,16 @@ class GlancesCurses(object):
|
||||
else:
|
||||
return c + 1
|
||||
|
||||
class glances_textbox(Textbox):
|
||||
"""
|
||||
"""
|
||||
def __init__(*args, **kwargs):
|
||||
Textbox.__init__(*args, **kwargs)
|
||||
|
||||
def do_command(self, ch):
|
||||
if ch == 10: # Enter
|
||||
return 0
|
||||
if ch == 127: # Enter
|
||||
return 8
|
||||
return Textbox.do_command(self, ch)
|
||||
if not is_windows:
|
||||
class glances_textbox(Textbox):
|
||||
"""
|
||||
"""
|
||||
def __init__(*args, **kwargs):
|
||||
Textbox.__init__(*args, **kwargs)
|
||||
|
||||
def do_command(self, ch):
|
||||
if ch == 10: # Enter
|
||||
return 0
|
||||
if ch == 127: # Enter
|
||||
return 8
|
||||
return Textbox.do_command(self, ch)
|
Loading…
Reference in New Issue
Block a user