From 2695f313b764e05d416d31f90ff913eca7fb9a32 Mon Sep 17 00:00:00 2001 From: dshaligram Date: Mon, 8 Oct 2007 11:58:07 +0000 Subject: Make Escape cancel out of menu and prompt for the ability and spellcasting menus (Marc). git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@2373 c06c8d41-db1a-0410-9941-cceddc491573 --- crawl-ref/source/abl-show.cc | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'crawl-ref/source/abl-show.cc') diff --git a/crawl-ref/source/abl-show.cc b/crawl-ref/source/abl-show.cc index be68ecf8fd..77ebf6ab4a 100644 --- a/crawl-ref/source/abl-show.cc +++ b/crawl-ref/source/abl-show.cc @@ -844,6 +844,11 @@ bool activate_ability() if ( keyin == '?' || keyin == '*' ) { selected = choose_ability_menu(talents); + if (selected == -1) + { + canned_msg( MSG_OK ); + return (false); + } } else if (keyin == ESCAPE || keyin == ' ' || keyin == '\r' || keyin == '\n') @@ -1820,7 +1825,9 @@ int choose_ability_menu(const std::vector& talents) { Menu abil_menu(MF_SINGLESELECT | MF_ANYPRINTABLE); abil_menu.set_highlighter(NULL); - abil_menu.set_title(new MenuEntry(" Ability Cost Success")); + abil_menu.set_title( + new MenuEntry(" Ability " + "Cost Success")); int numbers[52]; for ( int i = 0; i < 52; ++i ) -- cgit v1.2.3-54-g00ecf