2002-10-28 Yoshinori K. Okuji <okuji@enbug.org>

* grub/asmstub.c (console_translate_key): Deal with KEY_PPAGE
	and KEY_NPAGE.
	* stage2/serial.c (serial_translate_key_sequence): Added two new
	codes for Page Up and Page Down.
	* stage2/asm.S (translation_table): Added entries for KEY_PPAGE
	and KEY_NPAGE.
	* stage2/stage2.c (run_menu): Deal with Page Up and Page Down.
	Also recognize the right key for the selection of a boot entry.
	Suggested by Adam Lackorzynski <adam@os.inf.tu-dresden.de>.
This commit is contained in:
okuji 2002-10-27 23:59:53 +00:00
parent ca305dc1b1
commit 76deb4cec4
7 changed files with 50 additions and 2 deletions

View file

@ -1,3 +1,15 @@
2002-10-28 Yoshinori K. Okuji <okuji@enbug.org>
* grub/asmstub.c (console_translate_key): Deal with KEY_PPAGE
and KEY_NPAGE.
* stage2/serial.c (serial_translate_key_sequence): Added two new
codes for Page Up and Page Down.
* stage2/asm.S (translation_table): Added entries for KEY_PPAGE
and KEY_NPAGE.
* stage2/stage2.c (run_menu): Deal with Page Up and Page Down.
Also recognize the right key for the selection of a boot entry.
Suggested by Adam Lackorzynski <adam@os.inf.tu-dresden.de>.
2002-10-10 Jason Thomas <jason@topic.com.au> 2002-10-10 Jason Thomas <jason@topic.com.au>
* stage2/builtins.c (setup_func): Added missing space to --force-lba * stage2/builtins.c (setup_func): Added missing space to --force-lba

1
NEWS
View file

@ -22,6 +22,7 @@ New in 0.93:
if the passwords match. if the passwords match.
* Support for booting Linux is rewritten, so GRUB now supports * Support for booting Linux is rewritten, so GRUB now supports
large-EBDA systems. large-EBDA systems.
* The menu interfaces supports Page Up, Page Down, and Right Key.
New in 0.92 - 2002-04-30: New in 0.92 - 2002-04-30:
* The command "displaymem" uses only hex digits for consistency. * The command "displaymem" uses only hex digits for consistency.

1
THANKS
View file

@ -6,6 +6,7 @@ The following people made especially gracious contributions of their
time and energy in helping to track down bugs, add new features, and time and energy in helping to track down bugs, add new features, and
generally assist in the GRUB maintainership process: generally assist in the GRUB maintainership process:
Adam Lackorzynski <adam@os.inf.tu-dresden.de>
Adrian Phillips <a.phillips@dnmi.no> Adrian Phillips <a.phillips@dnmi.no>
Alessandro Rubini <rubini@gnu.org> Alessandro Rubini <rubini@gnu.org>
Alexander K. Hudek <alexhudek@home.com> Alexander K. Hudek <alexhudek@home.com>

View file

@ -627,6 +627,10 @@ console_translate_key (int c)
return 1; return 1;
case KEY_END: case KEY_END:
return 5; return 5;
case KEY_PPAGE:
return 7;
case KEY_NPAGE:
return 3;
default: default:
break; break;
} }

View file

@ -1920,6 +1920,8 @@ translation_table:
.word KEY_END, 5 .word KEY_END, 5
.word KEY_DC, 4 .word KEY_DC, 4
.word KEY_BACKSPACE, 8 .word KEY_BACKSPACE, 8
.word KEY_PPAGE, 7
.word KEY_NPAGE, 3
.word 0 .word 0
/* /*

View file

@ -218,7 +218,9 @@ serial_translate_key_sequence (void)
four_code_table[] = four_code_table[] =
{ {
{('1' | ('~' << 8)), 1}, {('1' | ('~' << 8)), 1},
{('3' | ('~' << 8)), 4} {('3' | ('~' << 8)), 4},
{('5' | ('~' << 8)), 7},
{('6' | ('~' << 8)), 3},
}; };
/* The buffer must start with ``ESC [''. */ /* The buffer must start with ``ESC [''. */

View file

@ -447,10 +447,36 @@ restart:
} }
} }
} }
else if (c == 7)
{
/* Page Up */
first_entry -= 12;
if (first_entry < 0)
{
entryno += first_entry;
first_entry = 0;
if (entryno < 0)
entryno = 0;
}
print_entries (3, 12, first_entry, entryno, menu_entries);
}
else if (c == 3)
{
/* Page Down */
first_entry += 12;
if (first_entry + entryno + 1 >= num_entries)
{
first_entry = num_entries - 12;
if (first_entry < 0)
first_entry = 0;
entryno = num_entries - first_entry - 1;
}
print_entries (3, 12, first_entry, entryno, menu_entries);
}
if (config_entries) if (config_entries)
{ {
if ((c == '\n') || (c == '\r')) if ((c == '\n') || (c == '\r') || (c == 6))
break; break;
} }
else else