* [PATCH] nconf: handle comment entries within choice/endchoice
@ 2011-01-06 15:42 Peter Korsgaard
2011-01-07 15:02 ` Michal Marek
0 siblings, 1 reply; 3+ messages in thread
From: Peter Korsgaard @ 2011-01-06 15:42 UTC (permalink / raw)
To: mmarek, nir.tzachar, sam, linux-kbuild; +Cc: Peter Korsgaard
Equivalent to af6c1598 (kconfig: handle comment entries within
choice/endchoice), but for nconfig instead.
Implement support for comment entries within choice groups. Comment entries
are displayed visually distinct from normal configs, and selecting them is
a no-op.
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
---
scripts/kconfig/nconf.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/scripts/kconfig/nconf.c b/scripts/kconfig/nconf.c
index 272a987..f343105 100644
--- a/scripts/kconfig/nconf.c
+++ b/scripts/kconfig/nconf.c
@@ -1266,9 +1266,13 @@ static void conf_choice(struct menu *menu)
if (child->sym == sym_get_choice_value(menu->sym))
item_make(child, ':', "<X> %s",
_(menu_get_prompt(child)));
- else
+ else if (child->sym)
item_make(child, ':', " %s",
_(menu_get_prompt(child)));
+ else
+ item_make(child, ':', "*** %s ***",
+ _(menu_get_prompt(child)));
+
if (child->sym == active){
last_top_row = top_row(curses_menu);
selected_index = i;
@@ -1334,7 +1338,7 @@ static void conf_choice(struct menu *menu)
break;
child = item_data();
- if (!child || !menu_is_visible(child))
+ if (!child || !menu_is_visible(child) || !child->sym)
continue;
switch (res) {
case ' ':
--
1.7.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] nconf: handle comment entries within choice/endchoice
2011-01-06 15:42 [PATCH] nconf: handle comment entries within choice/endchoice Peter Korsgaard
@ 2011-01-07 15:02 ` Michal Marek
2011-01-07 22:32 ` Peter Korsgaard
0 siblings, 1 reply; 3+ messages in thread
From: Michal Marek @ 2011-01-07 15:02 UTC (permalink / raw)
To: Peter Korsgaard; +Cc: nir.tzachar, sam, linux-kbuild
On Thu, Jan 06, 2011 at 04:42:45PM +0100, Peter Korsgaard wrote:
> Equivalent to af6c1598 (kconfig: handle comment entries within
> choice/endchoice), but for nconfig instead.
>
> Implement support for comment entries within choice groups. Comment entries
> are displayed visually distinct from normal configs, and selecting them is
> a no-op.
>
> Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
> ---
> scripts/kconfig/nconf.c | 8 ++++++--
> 1 files changed, 6 insertions(+), 2 deletions(-)
OK, applied, but is this actually used somewhere?
Michal
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] nconf: handle comment entries within choice/endchoice
2011-01-07 15:02 ` Michal Marek
@ 2011-01-07 22:32 ` Peter Korsgaard
0 siblings, 0 replies; 3+ messages in thread
From: Peter Korsgaard @ 2011-01-07 22:32 UTC (permalink / raw)
To: Michal Marek; +Cc: nir.tzachar, sam, linux-kbuild
On Fri, Jan 7, 2011 at 4:02 PM, Michal Marek <mmarek@suse.cz> wrote:
> OK, applied, but is this actually used somewhere?
Afaik nowhere in the kernel, but we do use it in Buildroot (which uses
kconfig like several other projects).
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-01-07 22:32 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-01-06 15:42 [PATCH] nconf: handle comment entries within choice/endchoice Peter Korsgaard
2011-01-07 15:02 ` Michal Marek
2011-01-07 22:32 ` Peter Korsgaard
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox