From 4d1f668fd9be725d9a5cac6209505ca9b113e1f9 Mon Sep 17 00:00:00 2001 From: Carles Pina i Estany Date: Sun, 22 Nov 2009 22:24:54 +0000 Subject: [PATCH] 2009-11-22 Carles Pina i Estany * normal/menu_text.c: Gettexttize but not print_timeout function. * normal/main.c: Gettexttize. * normal/menu_entry.c: Likewise. --- ChangeLog.gettext2 | 5 +++++ normal/main.c | 5 +++-- normal/menu_entry.c | 5 +++-- normal/menu_text.c | 20 ++++++++++---------- 4 files changed, 21 insertions(+), 14 deletions(-) create mode 100644 ChangeLog.gettext2 diff --git a/ChangeLog.gettext2 b/ChangeLog.gettext2 new file mode 100644 index 000000000..0aee7e2e4 --- /dev/null +++ b/ChangeLog.gettext2 @@ -0,0 +1,5 @@ +2009-11-22 Carles Pina i Estany + + * normal/menu_text.c: Gettexttize but not print_timeout function. + * normal/main.c: Gettexttize. + * normal/menu_entry.c: Likewise. diff --git a/normal/main.c b/normal/main.c index 748eef805..afe3667f3 100644 --- a/normal/main.c +++ b/normal/main.c @@ -29,6 +29,7 @@ #include #include #include +#include #define GRUB_DEFAULT_HISTORY_SIZE 50 @@ -508,10 +509,10 @@ grub_normal_reader_init (void) grub_normal_init_page (); grub_setcursor (1); - grub_printf ("\ + grub_printf (_("\ [ Minimal BASH-like line editing is supported. For the first word, TAB\n\ lists possible command completions. Anywhere else TAB lists possible\n\ - device/file completions.%s ]\n\n", + device/file completions.%s ]\n\n"), reader_nested ? " ESC at any time exits." : ""); return 0; diff --git a/normal/menu_entry.c b/normal/menu_entry.c index 75a63779f..7478c33ae 100644 --- a/normal/menu_entry.c +++ b/normal/menu_entry.c @@ -24,6 +24,7 @@ #include #include #include +#include enum update_mode { @@ -996,7 +997,7 @@ run (struct screen *screen) } grub_cls (); - grub_printf (" Booting a command list\n\n"); + grub_printf (_(" Booting a command list\n\n")); /* Execute the script, line for line. */ @@ -1176,6 +1177,6 @@ grub_menu_entry_run (grub_menu_entry_t entry) grub_cls (); grub_print_error (); grub_errno = GRUB_ERR_NONE; - grub_printf ("\nPress any key to continue..."); + grub_printf (_("\nPress any key to continue...")); (void) grub_getkey (); } diff --git a/normal/menu_text.c b/normal/menu_text.c index 4ff22e928..de28205de 100644 --- a/normal/menu_text.c +++ b/normal/menu_text.c @@ -39,7 +39,7 @@ static grub_uint8_t grub_color_menu_highlight; void grub_wait_after_message (void) { - grub_printf ("\nPress any key to continue..."); + grub_printf (_("\nPress any key to continue...")); (void) grub_getkey (); grub_putchar ('\n'); } @@ -87,22 +87,22 @@ print_message (int nested, int edit) if (edit) { - grub_printf ("\n\ + grub_printf (_("\n\ Minimum Emacs-like screen editing is supported. TAB lists\n\ completions. Press Ctrl-x to boot, Ctrl-c for a command-line\n\ - or ESC to return menu."); + or ESC to return menu.")); } else { grub_printf (_("\n\ Use the %C and %C keys to select which entry is highlighted.\n"), (grub_uint32_t) GRUB_TERM_DISP_UP, (grub_uint32_t) GRUB_TERM_DISP_DOWN); - grub_printf ("\ + grub_printf (_("\ Press enter to boot the selected OS, \'e\' to edit the\n\ - commands before booting or \'c\' for a command-line."); + commands before booting or \'c\' for a command-line.")); if (nested) - grub_printf ("\n\ - ESC to return previous menu."); + grub_printf (_("\n\ + ESC to return previous menu.")); } } @@ -517,7 +517,7 @@ static void notify_booting (grub_menu_entry_t entry, void *userdata __attribute__((unused))) { - grub_printf (" Booting \'%s\'\n\n", entry->title); + grub_printf (_(" Booting \'%s\'\n\n"), entry->title); } /* Callback invoked when a default menu entry executed because of a timeout @@ -527,7 +527,7 @@ static void notify_fallback (grub_menu_entry_t entry, void *userdata __attribute__((unused))) { - grub_printf ("\n Falling back to \'%s\'\n\n", entry->title); + grub_printf (_("\n Falling back to \'%s\'\n\n"), entry->title); grub_millisleep (DEFAULT_ENTRY_ERROR_DELAY_MS); } @@ -541,7 +541,7 @@ notify_execution_failure (void *userdata __attribute__((unused))) grub_print_error (); grub_errno = GRUB_ERR_NONE; } - grub_printf ("\n Failed to boot default entries.\n"); + grub_printf (_("\n Failed to boot default entries.\n")); grub_wait_after_message (); }