summaryrefslogtreecommitdiffstats
path: root/scripts/kconfig/nconf.gui.c
diff options
context:
space:
mode:
authorCheng Renquan <crquan@gmail.com>2011-09-01 10:52:22 -0700
committerMichal Marek <mmarek@suse.cz>2011-09-09 14:40:08 +0200
commit93072c3ecafcf188390750cc755185f3150736b9 (patch)
tree96e03b8e1dd1d61dd36e967780d80c64ffbf6376 /scripts/kconfig/nconf.gui.c
parente631a57a19e103c3bb59495b236634ec62e2a850 (diff)
downloadop-kernel-dev-93072c3ecafcf188390750cc755185f3150736b9.zip
op-kernel-dev-93072c3ecafcf188390750cc755185f3150736b9.tar.gz
scripts/kconfig/nconf: add KEY_HOME / KEY_END for dialog_inputbox
to make it easier to locate begin/end when editing long strings; Signed-off-by: Cheng Renquan <crquan@gmail.com> Acked By: Nir Tzachar <nir.tzachar@gmail.com>
Diffstat (limited to 'scripts/kconfig/nconf.gui.c')
-rw-r--r--scripts/kconfig/nconf.gui.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/scripts/kconfig/nconf.gui.c b/scripts/kconfig/nconf.gui.c
index 4b9d8b6..3b18dd8 100644
--- a/scripts/kconfig/nconf.gui.c
+++ b/scripts/kconfig/nconf.gui.c
@@ -465,6 +465,14 @@ int dialog_inputbox(WINDOW *main_window,
cursor_form_win--;
}
break;
+ case KEY_HOME:
+ cursor_position = 0;
+ cursor_form_win = 0;
+ break;
+ case KEY_END:
+ cursor_position = len;
+ cursor_form_win = min(cursor_position, prompt_width-1);
+ break;
default:
if ((isgraph(res) || isspace(res))) {
/* one for new char, one for '\0' */
OpenPOWER on IntegriCloud