* include/grub/command.h (GRUB_COMMAND_FLAG_CMDLINE): Removed. All

users updated.
	(GRUB_COMMAND_FLAG_MENU): Likewise.
	(GRUB_COMMAND_FLAG_BOTH): Likewise.
	(GRUB_COMMAND_FLAG_TITLE): Removed.
	(GRUB_COMMAND_FLAG_NO_ECHO): Likewise.
	(GRUB_COMMAND_FLAG_EXTCMD): Moved into enum.
	(GRUB_COMMAND_FLAG_DYNCMD): Likewise.
	(GRUB_COMMAND_FLAG_BLOCKS): Likewise.
	(grub_command_flags_t): New enum. All users updated.
This commit is contained in:
Vladimir 'phcoder' Serbinenko 2010-09-14 23:06:01 +02:00
parent 5fe7620a4e
commit ed80f7d586
39 changed files with 76 additions and 104 deletions

View file

@ -23,22 +23,15 @@
#include <grub/err.h>
#include <grub/list.h>
/* Can be run in the command-line. */
#define GRUB_COMMAND_FLAG_CMDLINE 0x1
/* Can be run in the menu. */
#define GRUB_COMMAND_FLAG_MENU 0x2
/* Can be run in both interfaces. */
#define GRUB_COMMAND_FLAG_BOTH 0x3
/* Only for the command title. */
#define GRUB_COMMAND_FLAG_TITLE 0x4
/* Don't print the command on booting. */
#define GRUB_COMMAND_FLAG_NO_ECHO 0x8
/* This is an extended command. */
#define GRUB_COMMAND_FLAG_EXTCMD 0x10
/* This is an dynamic command. */
#define GRUB_COMMAND_FLAG_DYNCMD 0x20
/* This command accepts block arguments. */
#define GRUB_COMMAND_FLAG_BLOCKS 0x40
typedef enum grub_command_flags
{
/* This is an extended command. */
GRUB_COMMAND_FLAG_EXTCMD = 0x10,
/* This is an dynamic command. */
GRUB_COMMAND_FLAG_DYNCMD = 0x20,
/* This command accepts block arguments. */
GRUB_COMMAND_FLAG_BLOCKS = 0x40
} grub_command_flags_t;
struct grub_command;
@ -61,7 +54,7 @@ struct grub_command
grub_command_func_t func;
/* The flags. */
unsigned flags;
grub_command_flags_t flags;
/* The summary of the command usage. */
const char *summary;

View file

@ -57,14 +57,14 @@ typedef struct grub_extcmd_context *grub_extcmd_context_t;
grub_extcmd_t grub_register_extcmd (const char *name,
grub_extcmd_func_t func,
unsigned flags,
grub_command_flags_t flags,
const char *summary,
const char *description,
const struct grub_arg_option *parser);
grub_extcmd_t grub_register_extcmd_prio (const char *name,
grub_extcmd_func_t func,
unsigned flags,
grub_command_flags_t flags,
const char *summary,
const char *description,
const struct grub_arg_option *parser,