aboutsummaryrefslogtreecommitdiff
path: root/libbb/lineedit.c
diff options
context:
space:
mode:
authorPaul Fox <pgf@brightstareng.com>2008-01-18 20:41:24 +0000
committerPaul Fox <pgf@brightstareng.com>2008-01-18 20:41:24 +0000
commit518d8dd97949be5303a405bedd26d0f325854c84 (patch)
tree5c14e2e97d6abd7df39fbe3897d4f5ec720a7fc9 /libbb/lineedit.c
parent52432f2b06c28038fbe60f0eed80905ac7ff7ee5 (diff)
downloadbusybox-w32-518d8dd97949be5303a405bedd26d0f325854c84.tar.gz
busybox-w32-518d8dd97949be5303a405bedd26d0f325854c84.tar.bz2
busybox-w32-518d8dd97949be5303a405bedd26d0f325854c84.zip
eliminated CONFIG_FEATURE_EDITING_FANCY_KEYS. the size savings
was small, compared to the total size of the command-line editing features, and it removed key bindings that most wouldn't consider "fancy", like ^U, and 'l' and 'h' in vi mode, ^F and ^B in emacs mode.
Diffstat (limited to 'libbb/lineedit.c')
-rw-r--r--libbb/lineedit.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/libbb/lineedit.c b/libbb/lineedit.c
index cbe2bb916..d3ee7386e 100644
--- a/libbb/lineedit.c
+++ b/libbb/lineedit.c
@@ -1423,7 +1423,6 @@ int read_line_input(const char *prompt, char *command, int maxsize, line_input_t
1423 goto_new_line(); 1423 goto_new_line();
1424 break_out = 1; 1424 break_out = 1;
1425 break; 1425 break;
1426#if ENABLE_FEATURE_EDITING_FANCY_KEYS
1427 case CTRL('A'): 1426 case CTRL('A'):
1428 vi_case('0'|vbit:) 1427 vi_case('0'|vbit:)
1429 /* Control-a -- Beginning of line */ 1428 /* Control-a -- Beginning of line */
@@ -1436,7 +1435,6 @@ int read_line_input(const char *prompt, char *command, int maxsize, line_input_t
1436 /* Control-b -- Move back one character */ 1435 /* Control-b -- Move back one character */
1437 input_backward(1); 1436 input_backward(1);
1438 break; 1437 break;
1439#endif
1440 case CTRL('C'): 1438 case CTRL('C'):
1441 vi_case(CTRL('C')|vbit:) 1439 vi_case(CTRL('C')|vbit:)
1442 /* Control-c -- stop gathering input */ 1440 /* Control-c -- stop gathering input */
@@ -1457,7 +1455,6 @@ int read_line_input(const char *prompt, char *command, int maxsize, line_input_t
1457 input_delete(0); 1455 input_delete(0);
1458 break; 1456 break;
1459 1457
1460#if ENABLE_FEATURE_EDITING_FANCY_KEYS
1461 case CTRL('E'): 1458 case CTRL('E'):
1462 vi_case('$'|vbit:) 1459 vi_case('$'|vbit:)
1463 /* Control-e -- End of line */ 1460 /* Control-e -- End of line */
@@ -1469,7 +1466,6 @@ int read_line_input(const char *prompt, char *command, int maxsize, line_input_t
1469 /* Control-f -- Move forward one character */ 1466 /* Control-f -- Move forward one character */
1470 input_forward(); 1467 input_forward();
1471 break; 1468 break;
1472#endif
1473 1469
1474 case '\b': 1470 case '\b':
1475 case '\x7f': /* DEL */ 1471 case '\x7f': /* DEL */
@@ -1483,7 +1479,6 @@ int read_line_input(const char *prompt, char *command, int maxsize, line_input_t
1483 break; 1479 break;
1484#endif 1480#endif
1485 1481
1486#if ENABLE_FEATURE_EDITING_FANCY_KEYS
1487 case CTRL('K'): 1482 case CTRL('K'):
1488 /* Control-k -- clear to end of line */ 1483 /* Control-k -- clear to end of line */
1489 command[cursor] = 0; 1484 command[cursor] = 0;
@@ -1496,7 +1491,6 @@ int read_line_input(const char *prompt, char *command, int maxsize, line_input_t
1496 printf("\033[H"); 1491 printf("\033[H");
1497 redraw(0, command_len - cursor); 1492 redraw(0, command_len - cursor);
1498 break; 1493 break;
1499#endif
1500 1494
1501#if MAX_HISTORY > 0 1495#if MAX_HISTORY > 0
1502 case CTRL('N'): 1496 case CTRL('N'):
@@ -1518,7 +1512,6 @@ int read_line_input(const char *prompt, char *command, int maxsize, line_input_t
1518 break; 1512 break;
1519#endif 1513#endif
1520 1514
1521#if ENABLE_FEATURE_EDITING_FANCY_KEYS
1522 case CTRL('U'): 1515 case CTRL('U'):
1523 vi_case(CTRL('U')|vbit:) 1516 vi_case(CTRL('U')|vbit:)
1524 /* Control-U -- Clear line before cursor */ 1517 /* Control-U -- Clear line before cursor */
@@ -1528,7 +1521,6 @@ int read_line_input(const char *prompt, char *command, int maxsize, line_input_t
1528 redraw(cmdedit_y, command_len); 1521 redraw(cmdedit_y, command_len);
1529 } 1522 }
1530 break; 1523 break;
1531#endif
1532 case CTRL('W'): 1524 case CTRL('W'):
1533 vi_case(CTRL('W')|vbit:) 1525 vi_case(CTRL('W')|vbit:)
1534 /* Control-W -- Remove the last word */ 1526 /* Control-W -- Remove the last word */