[Scummvm-cvs-logs] SF.net SVN: scummvm:[47186] scummvm/trunk/engines/sci
m_kiewitz at users.sourceforge.net
m_kiewitz at users.sourceforge.net
Fri Jan 8 23:52:50 CET 2010
Revision: 47186
http://scummvm.svn.sourceforge.net/scummvm/?rev=47186&view=rev
Author: m_kiewitz
Date: 2010-01-08 22:52:50 +0000 (Fri, 08 Jan 2010)
Log Message:
-----------
SCI: removed controlify() to ease readability of code
Modified Paths:
--------------
scummvm/trunk/engines/sci/event.cpp
scummvm/trunk/engines/sci/event.h
Modified: scummvm/trunk/engines/sci/event.cpp
===================================================================
--- scummvm/trunk/engines/sci/event.cpp 2010-01-08 22:45:38 UTC (rev 47185)
+++ scummvm/trunk/engines/sci/event.cpp 2010-01-08 22:52:50 UTC (rev 47186)
@@ -51,12 +51,6 @@
{0x2c, "ZXCVBNM,./"}
};
-int SciEvent::controlify(int ch) {
- if (ch < 26)
- ch += 96; // 0x01 -> 'a'
- return ch;
-}
-
int SciEvent::altify (int ch) {
// Calculates a PC keyboard scancode from a character */
int row;
@@ -369,7 +363,7 @@
// we support the other case as well
if (event.modifiers & SCI_KEYMOD_ALT) {
if (event.character < 26)
- event.character += 96;
+ event.character += 96; // 0x01 -> 'a'
}
if (getSciVersion() <= SCI_VERSION_1_MIDDLE) {
@@ -378,8 +372,8 @@
if (event.modifiers & SCI_KEYMOD_ALT) {
event.character = altify(event.character);
} else if (event.modifiers & SCI_KEYMOD_CTRL) {
- //event.character = event.data;
- event.character = controlify(event.character);
+ if (event.character < 26)
+ event.character += 96; // 0x01 -> 'a'
}
}
Modified: scummvm/trunk/engines/sci/event.h
===================================================================
--- scummvm/trunk/engines/sci/event.h 2010-01-08 22:45:38 UTC (rev 47185)
+++ scummvm/trunk/engines/sci/event.h 2010-01-08 22:52:50 UTC (rev 47186)
@@ -119,7 +119,6 @@
sciEvent get(unsigned int mask);
private:
- int controlify (int ch);
int altify (int ch);
int shiftify (int c);
int numlockify (int c);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list