summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/tilereg-title.cc
diff options
context:
space:
mode:
authorRaphael Langella <raphael.langella@gmail.com>2011-02-10 15:55:10 +0100
committerRaphael Langella <raphael.langella@gmail.com>2011-02-10 20:55:29 +0100
commit7a657cdb01a6fb74ff8cf8fcaeeb81d375a7bb04 (patch)
tree549060415abfbd99ac14a7809d41d8e11249cd62 /crawl-ref/source/tilereg-title.cc
parentaf62abd18c2e011fb9bf912e33374e7d78a2c733 (diff)
downloadcrawl-ref-7a657cdb01a6fb74ff8cf8fcaeeb81d375a7bb04.tar.gz
crawl-ref-7a657cdb01a6fb74ff8cf8fcaeeb81d375a7bb04.zip
Fix click on the title screen making selection in the startup menu.
Diffstat (limited to 'crawl-ref/source/tilereg-title.cc')
-rw-r--r--crawl-ref/source/tilereg-title.cc11
1 files changed, 9 insertions, 2 deletions
diff --git a/crawl-ref/source/tilereg-title.cc b/crawl-ref/source/tilereg-title.cc
index 9f23e5f179..3da752dc23 100644
--- a/crawl-ref/source/tilereg-title.cc
+++ b/crawl-ref/source/tilereg-title.cc
@@ -10,6 +10,7 @@
#include "tilereg-title.h"
+#include "cio.h"
#include "files.h"
#include "libutil.h"
#include "macro.h"
@@ -55,8 +56,7 @@ void TitleRegion::render()
void TitleRegion::run()
{
- mouse_control mc(MOUSE_MODE_MORE);
- getchm();
+ getch_ck();
}
/**
@@ -69,4 +69,11 @@ void TitleRegion::update_message(std::string message)
m_font_buf.add(message, VColour::white, 0, 0);
}
+int TitleRegion::handle_mouse(MouseEvent &event)
+{
+ if (event.event == MouseEvent::RELEASE)
+ return CK_MOUSE_CLICK;
+ else
+ return 0;
+}
#endif