Lines Matching +full:key +full:- +full:2
1 // SPDX-License-Identifier: GPL-2.0
23 ui_browser__write_nstring(browser, *arg, browser->width); in ui_browser__argv_write()
28 int key; in popup_menu__run() local
30 if (ui_browser__show(menu, " ", "ESC: exit, ENTER|->: Select option") < 0) in popup_menu__run()
31 return -1; in popup_menu__run()
34 key = ui_browser__run(menu, 0); in popup_menu__run()
36 switch (key) { in popup_menu__run()
39 key = menu->index; in popup_menu__run()
45 key = -1; in popup_menu__run()
49 *keyp = key; in popup_menu__run()
50 key = menu->nr_entries; in popup_menu__run()
60 return key; in popup_menu__run()
78 int x, y, len, key; in ui_browser__input_window() local
89 len = sep - t; in ui_browser__input_window()
100 max_len += 2; in ui_browser__input_window()
102 y = SLtt_Screen_Rows / 2 - nr_lines / 2; in ui_browser__input_window()
103 x = SLtt_Screen_Cols / 2 - max_len / 2; in ui_browser__input_window()
112 nr_lines -= 7; in ui_browser__input_window()
113 max_len -= 2; in ui_browser__input_window()
118 while (len--) { in ui_browser__input_window()
119 SLsmg_gotorc(y + len - 1, x); in ui_browser__input_window()
122 SLsmg_draw_box(y++, x + 1, 3, max_len - 2); in ui_browser__input_window()
130 x += 2; in ui_browser__input_window()
132 key = ui__getch(delay_secs); in ui_browser__input_window()
133 while (key != K_TIMER && key != K_ENTER && key != K_ESC) { in ui_browser__input_window()
136 if (key == K_BKSPC) { in ui_browser__input_window()
141 SLsmg_gotorc(y, x + --len); in ui_browser__input_window()
144 buf[len] = key; in ui_browser__input_window()
146 SLsmg_write_char(key); in ui_browser__input_window()
153 if (len == sizeof(buf) - 1) { in ui_browser__input_window()
155 key = K_ENTER; in ui_browser__input_window()
159 key = ui__getch(delay_secs); in ui_browser__input_window()
164 return key; in ui_browser__input_window()
180 len = sep - t; in __ui__info_window()
189 max_len += 2; in __ui__info_window()
190 nr_lines += 2; in __ui__info_window()
192 nr_lines += 2; in __ui__info_window()
193 y = SLtt_Screen_Rows / 2 - nr_lines / 2, in __ui__info_window()
194 x = SLtt_Screen_Cols / 2 - max_len / 2; in __ui__info_window()
204 nr_lines -= 2; in __ui__info_window()
205 max_len -= 2; in __ui__info_window()
209 SLsmg_gotorc(y + nr_lines - 2, x); in __ui__info_window()
211 SLsmg_gotorc(y + nr_lines - 1, x); in __ui__info_window()
236 return ui__question_window("Help", text, "Press any key...", 0); in ui__help_window()
249 int key; in __ui__warning() local
251 key = ui__question_window(title, s, "Press any key...", 0); in __ui__warning()
253 return key; in __ui__warning()