mirror of
https://git.jabber.space/devs/cproof.git
synced 2026-08-01 18:26:22 +00:00
Basic resize of bars
This commit is contained in:
@@ -87,6 +87,10 @@ void inp_get_char(int *ch, char *input, int *size)
|
|||||||
noecho();
|
noecho();
|
||||||
*ch = wgetch(inp_win);
|
*ch = wgetch(inp_win);
|
||||||
|
|
||||||
|
if (*ch == KEY_RESIZE) {
|
||||||
|
cons_show("REZISE SIGNAL");
|
||||||
|
win_resize();
|
||||||
|
} else {
|
||||||
// if it wasn't an arrow key etc
|
// if it wasn't an arrow key etc
|
||||||
if (!_handle_edit(*ch, input, size)) {
|
if (!_handle_edit(*ch, input, size)) {
|
||||||
if (_printable(*ch)) {
|
if (_printable(*ch)) {
|
||||||
@@ -112,6 +116,7 @@ void inp_get_char(int *ch, char *input, int *size)
|
|||||||
reset_search_attempts();
|
reset_search_attempts();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
echo();
|
echo();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -88,6 +88,14 @@ void gui_init(void)
|
|||||||
dirty = TRUE;
|
dirty = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void win_resize(void)
|
||||||
|
{
|
||||||
|
create_title_bar();
|
||||||
|
create_status_bar();
|
||||||
|
create_input_window();
|
||||||
|
dirty = TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
void gui_refresh(void)
|
void gui_refresh(void)
|
||||||
{
|
{
|
||||||
title_bar_refresh();
|
title_bar_refresh();
|
||||||
|
|||||||
@@ -37,6 +37,7 @@ struct prof_win {
|
|||||||
void gui_init(void);
|
void gui_init(void);
|
||||||
void gui_refresh(void);
|
void gui_refresh(void);
|
||||||
void gui_close(void);
|
void gui_close(void);
|
||||||
|
void win_resize(void);
|
||||||
|
|
||||||
// create windows
|
// create windows
|
||||||
void create_title_bar(void);
|
void create_title_bar(void);
|
||||||
|
|||||||
Reference in New Issue
Block a user