aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2011-11-03 13:28:22 +0100
committerDenys Vlasenko <vda.linux@googlemail.com>2011-11-03 13:28:22 +0100
commit9ce09bc9cb7743f87eb3e536c81d8c303e12bc81 (patch)
treead65a2f47136af7a730b630c4e08532c02ff0fb6 /include
parent45cdf166dccb4981004bae822f52e48df05aab91 (diff)
downloadbusybox-w32-9ce09bc9cb7743f87eb3e536c81d8c303e12bc81.tar.gz
busybox-w32-9ce09bc9cb7743f87eb3e536c81d8c303e12bc81.tar.bz2
busybox-w32-9ce09bc9cb7743f87eb3e536c81d8c303e12bc81.zip
lineedit: add support for M-b, M-f, M-d, M-Backspace
function old new delta ctrl_left - 96 +96 ctrl_right - 76 +76 static.esccmds 81 93 +12 read_line_input 3876 3885 +9 ------------------------------------------------------------------------------ (add/remove: 2/0 grow/shrink: 2/0 up/down: 193/0) Total: 193 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'include')
-rw-r--r--include/libbb.h46
1 files changed, 29 insertions, 17 deletions
diff --git a/include/libbb.h b/include/libbb.h
index 791cdd94e..53224fa35 100644
--- a/include/libbb.h
+++ b/include/libbb.h
@@ -1358,25 +1358,37 @@ enum {
1358 KEYCODE_DELETE = -9, 1358 KEYCODE_DELETE = -9,
1359 KEYCODE_PAGEUP = -10, 1359 KEYCODE_PAGEUP = -10,
1360 KEYCODE_PAGEDOWN = -11, 1360 KEYCODE_PAGEDOWN = -11,
1361 1361 // -12 is reserved for Alt/Ctrl/Shift-TAB
1362 KEYCODE_CTRL_UP = KEYCODE_UP & ~0x40, 1362#if 0
1363 KEYCODE_CTRL_DOWN = KEYCODE_DOWN & ~0x40, 1363 KEYCODE_FUN1 = -13,
1364 KEYCODE_FUN2 = -14,
1365 KEYCODE_FUN3 = -15,
1366 KEYCODE_FUN4 = -16,
1367 KEYCODE_FUN5 = -17,
1368 KEYCODE_FUN6 = -18,
1369 KEYCODE_FUN7 = -19,
1370 KEYCODE_FUN8 = -20,
1371 KEYCODE_FUN9 = -21,
1372 KEYCODE_FUN10 = -22,
1373 KEYCODE_FUN11 = -23,
1374 KEYCODE_FUN12 = -24,
1375#endif
1376 /* Be sure that last defined value is small enough
1377 * to not interfere with Alt/Ctrl/Shift bits.
1378 * So far we do not exceed -31 (0xfff..fffe1),
1379 * which gives us three upper bits in LSB to play with.
1380 */
1381 //KEYCODE_SHIFT_TAB = (-12) & ~0x80,
1382 //KEYCODE_SHIFT_... = KEYCODE_... & ~0x80,
1383 //KEYCODE_CTRL_UP = KEYCODE_UP & ~0x40,
1384 //KEYCODE_CTRL_DOWN = KEYCODE_DOWN & ~0x40,
1364 KEYCODE_CTRL_RIGHT = KEYCODE_RIGHT & ~0x40, 1385 KEYCODE_CTRL_RIGHT = KEYCODE_RIGHT & ~0x40,
1365 KEYCODE_CTRL_LEFT = KEYCODE_LEFT & ~0x40, 1386 KEYCODE_CTRL_LEFT = KEYCODE_LEFT & ~0x40,
1366#if 0 1387 //KEYCODE_ALT_UP = KEYCODE_UP & ~0x20,
1367 KEYCODE_FUN1 = -12, 1388 //KEYCODE_ALT_DOWN = KEYCODE_DOWN & ~0x20,
1368 KEYCODE_FUN2 = -13, 1389 KEYCODE_ALT_RIGHT = KEYCODE_RIGHT & ~0x20,
1369 KEYCODE_FUN3 = -14, 1390 KEYCODE_ALT_LEFT = KEYCODE_LEFT & ~0x20,
1370 KEYCODE_FUN4 = -15, 1391
1371 KEYCODE_FUN5 = -16,
1372 KEYCODE_FUN6 = -17,
1373 KEYCODE_FUN7 = -18,
1374 KEYCODE_FUN8 = -19,
1375 KEYCODE_FUN9 = -20,
1376 KEYCODE_FUN10 = -21,
1377 KEYCODE_FUN11 = -22,
1378 KEYCODE_FUN12 = -23,
1379#endif
1380 KEYCODE_CURSOR_POS = -0x100, /* 0xfff..fff00 */ 1392 KEYCODE_CURSOR_POS = -0x100, /* 0xfff..fff00 */
1381 /* How long is the longest ESC sequence we know? 1393 /* How long is the longest ESC sequence we know?
1382 * We want it big enough to be able to contain 1394 * We want it big enough to be able to contain