diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-06-01 11:55:52 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-06-01 11:55:52 -0400 |
commit | 1f73897861b8ef0be64ff4b801f8d6f830f683b5 (patch) | |
tree | b4bae8f12e1422113910d8cb00a19d010dc4a52f /scripts/kconfig/mconf.c | |
parent | b904d7131d116900524bd36ec170dcd97846bfd3 (diff) | |
parent | 64ffc9ff424c65adcffe7d590018cc75e2d5d42a (diff) |
Merge branch 'for-35' of git://repo.or.cz/linux-kbuild
* 'for-35' of git://repo.or.cz/linux-kbuild: (81 commits)
kbuild: Revert part of e8d400a to resolve a conflict
kbuild: Fix checking of scm-identifier variable
gconfig: add support to show hidden options that have prompts
menuconfig: add support to show hidden options which have prompts
gconfig: remove show_debug option
gconfig: remove dbg_print_ptype() and dbg_print_stype()
kconfig: fix zconfdump()
kconfig: some small fixes
add random binaries to .gitignore
kbuild: Include gen_initramfs_list.sh and the file list in the .d file
kconfig: recalc symbol value before showing search results
.gitignore: ignore *.lzo files
headerdep: perlcritic warning
scripts/Makefile.lib: Align the output of LZO
kbuild: Generate modules.builtin in make modules_install
Revert "kbuild: specify absolute paths for cscope"
kbuild: Do not unnecessarily regenerate modules.builtin
headers_install: use local file handles
headers_check: fix perl warnings
export_report: fix perl warnings
...
Diffstat (limited to 'scripts/kconfig/mconf.c')
-rw-r--r-- | scripts/kconfig/mconf.c | 36 |
1 files changed, 19 insertions, 17 deletions
diff --git a/scripts/kconfig/mconf.c b/scripts/kconfig/mconf.c index 8413cf38ed27..2c83d3234d30 100644 --- a/scripts/kconfig/mconf.c +++ b/scripts/kconfig/mconf.c | |||
@@ -67,13 +67,15 @@ static const char mconf_readme[] = N_( | |||
67 | " there is a delayed response which you may find annoying.\n" | 67 | " there is a delayed response which you may find annoying.\n" |
68 | "\n" | 68 | "\n" |
69 | " Also, the <TAB> and cursor keys will cycle between <Select>,\n" | 69 | " Also, the <TAB> and cursor keys will cycle between <Select>,\n" |
70 | " <Exit> and <Help>\n" | 70 | " <Exit> and <Help>.\n" |
71 | "\n" | 71 | "\n" |
72 | "o To get help with an item, use the cursor keys to highlight <Help>\n" | 72 | "o To get help with an item, use the cursor keys to highlight <Help>\n" |
73 | " and Press <ENTER>.\n" | 73 | " and press <ENTER>.\n" |
74 | "\n" | 74 | "\n" |
75 | " Shortcut: Press <H> or <?>.\n" | 75 | " Shortcut: Press <H> or <?>.\n" |
76 | "\n" | 76 | "\n" |
77 | "o To show hidden options, press <Z>.\n" | ||
78 | "\n" | ||
77 | "\n" | 79 | "\n" |
78 | "Radiolists (Choice lists)\n" | 80 | "Radiolists (Choice lists)\n" |
79 | "-----------\n" | 81 | "-----------\n" |
@@ -272,6 +274,7 @@ static int indent; | |||
272 | static struct menu *current_menu; | 274 | static struct menu *current_menu; |
273 | static int child_count; | 275 | static int child_count; |
274 | static int single_menu_mode; | 276 | static int single_menu_mode; |
277 | static int show_all_options; | ||
275 | 278 | ||
276 | static void conf(struct menu *menu); | 279 | static void conf(struct menu *menu); |
277 | static void conf_choice(struct menu *menu); | 280 | static void conf_choice(struct menu *menu); |
@@ -282,19 +285,6 @@ static void show_textbox(const char *title, const char *text, int r, int c); | |||
282 | static void show_helptext(const char *title, const char *text); | 285 | static void show_helptext(const char *title, const char *text); |
283 | static void show_help(struct menu *menu); | 286 | static void show_help(struct menu *menu); |
284 | 287 | ||
285 | static struct gstr get_relations_str(struct symbol **sym_arr) | ||
286 | { | ||
287 | struct symbol *sym; | ||
288 | struct gstr res = str_new(); | ||
289 | int i; | ||
290 | |||
291 | for (i = 0; sym_arr && (sym = sym_arr[i]); i++) | ||
292 | get_symbol_str(&res, sym); | ||
293 | if (!i) | ||
294 | str_append(&res, _("No matches found.\n")); | ||
295 | return res; | ||
296 | } | ||
297 | |||
298 | static char filename[PATH_MAX+1]; | 288 | static char filename[PATH_MAX+1]; |
299 | static void set_config_filename(const char *config_filename) | 289 | static void set_config_filename(const char *config_filename) |
300 | { | 290 | { |
@@ -359,8 +349,16 @@ static void build_conf(struct menu *menu) | |||
359 | int type, tmp, doint = 2; | 349 | int type, tmp, doint = 2; |
360 | tristate val; | 350 | tristate val; |
361 | char ch; | 351 | char ch; |
362 | 352 | bool visible; | |
363 | if (!menu_is_visible(menu)) | 353 | |
354 | /* | ||
355 | * note: menu_is_visible() has side effect that it will | ||
356 | * recalc the value of the symbol. | ||
357 | */ | ||
358 | visible = menu_is_visible(menu); | ||
359 | if (show_all_options && !menu_has_prompt(menu)) | ||
360 | return; | ||
361 | else if (!show_all_options && !visible) | ||
364 | return; | 362 | return; |
365 | 363 | ||
366 | sym = menu->sym; | 364 | sym = menu->sym; |
@@ -619,6 +617,9 @@ static void conf(struct menu *menu) | |||
619 | case 7: | 617 | case 7: |
620 | search_conf(); | 618 | search_conf(); |
621 | break; | 619 | break; |
620 | case 8: | ||
621 | show_all_options = !show_all_options; | ||
622 | break; | ||
622 | } | 623 | } |
623 | } | 624 | } |
624 | } | 625 | } |
@@ -638,6 +639,7 @@ static void show_help(struct menu *menu) | |||
638 | { | 639 | { |
639 | struct gstr help = str_new(); | 640 | struct gstr help = str_new(); |
640 | 641 | ||
642 | help.max_width = getmaxx(stdscr) - 10; | ||
641 | menu_get_ext_help(menu, &help); | 643 | menu_get_ext_help(menu, &help); |
642 | 644 | ||
643 | show_helptext(_(menu_get_prompt(menu)), str_get(&help)); | 645 | show_helptext(_(menu_get_prompt(menu)), str_get(&help)); |