summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/command.cc
diff options
context:
space:
mode:
authorharanp <haranp@c06c8d41-db1a-0410-9941-cceddc491573>2007-03-23 16:42:30 +0000
committerharanp <haranp@c06c8d41-db1a-0410-9941-cceddc491573>2007-03-23 16:42:30 +0000
commitdd4cbf50ea9f2f5163ee350079d97c930c28f0b5 (patch)
tree5cd72172416c52591fd9e0c1db9acf1407260687 /crawl-ref/source/command.cc
parent4a27e1a50d859e3e97c2ecd06cdd0a995a9a6977 (diff)
downloadcrawl-ref-dd4cbf50ea9f2f5163ee350079d97c930c28f0b5.tar.gz
crawl-ref-dd4cbf50ea9f2f5163ee350079d97c930c28f0b5.zip
Integrated David's manual changes.
Fixed help hotkeys so that the appendix hotkeys still work. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@1082 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/command.cc')
-rw-r--r--crawl-ref/source/command.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/crawl-ref/source/command.cc b/crawl-ref/source/command.cc
index d8839a5160..04717704c4 100644
--- a/crawl-ref/source/command.cc
+++ b/crawl-ref/source/command.cc
@@ -646,9 +646,10 @@ static void add_file_to_scroller(FILE* fp, formatted_scroller& m,
while (fgets(buf, sizeof buf, fp))
{
MenuEntry* me = new MenuEntry(buf);
- if ((next_is_hotkey && isupper(buf[0])) || (is_first && first_hotkey))
+ if ((next_is_hotkey && (isupper(buf[0]) || isdigit(buf[0]))) ||
+ (is_first && first_hotkey))
{
- int hotkey = is_first ? first_hotkey : tolower(buf[0]);
+ int hotkey = is_first ? first_hotkey : buf[0];
if ( !is_first && buf[0] == 'X' &&
strlen(buf) >= 3 && isdigit(buf[2]) )
{
@@ -656,6 +657,8 @@ static void add_file_to_scroller(FILE* fp, formatted_scroller& m,
hotkey = buf[2];
}
me->add_hotkey(hotkey);
+ if ( isupper(hotkey) )
+ me->add_hotkey(tolower(hotkey));
me->level = MEL_SUBTITLE;
me->colour = WHITE;
}