浏览代码

kconfig: make comments stand out in menuconfig

Matěj Laitl <strohel@gmail.com> noticed that there was no way
to distingush between comments and un-selectable menu lines.
This patch marks comments with *** comment ***

Cc: Matěj Laitl <strohel@gmail.com>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Sam Ravnborg 17 年之前
父节点
当前提交
48874077dd
共有 1 个文件被更改,包括 8 次插入0 次删除
  1. 8 0
      scripts/kconfig/mconf.c

+ 8 - 0
scripts/kconfig/mconf.c

@@ -481,6 +481,14 @@ static void build_conf(struct menu *menu)
 				if (single_menu_mode && menu->data)
 					goto conf_childs;
 				return;
+			case P_COMMENT:
+				if (prompt) {
+					child_count++;
+					item_make("   %*c*** %s ***", indent + 1, ' ', prompt);
+					item_set_tag(':');
+					item_set_data(menu);
+				}
+				break;
 			default:
 				if (prompt) {
 					child_count++;