aboutsummaryrefslogtreecommitdiff
path: root/engines/cge/events.cpp
diff options
context:
space:
mode:
authorPaul Gilbert2011-07-02 16:46:31 +1000
committerPaul Gilbert2011-07-02 16:46:31 +1000
commitd55401c2e10276827372f8df29418937cc2daf22 (patch)
tree5b5c38bcb2a51cfa89d24c9ae574e26825ca3ed8 /engines/cge/events.cpp
parent6833daab84a39a3d5dd0afcb176245f8678b28de (diff)
downloadscummvm-rg350-d55401c2e10276827372f8df29418937cc2daf22.tar.gz
scummvm-rg350-d55401c2e10276827372f8df29418937cc2daf22.tar.bz2
scummvm-rg350-d55401c2e10276827372f8df29418937cc2daf22.zip
CGE: Changed MOUSE class from using static fields to an instantiated class
Diffstat (limited to 'engines/cge/events.cpp')
-rw-r--r--engines/cge/events.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/engines/cge/events.cpp b/engines/cge/events.cpp
index e5ad00da5e..49b08e407b 100644
--- a/engines/cge/events.cpp
+++ b/engines/cge/events.cpp
@@ -34,10 +34,7 @@ namespace CGE {
/*----------------- KEYBOARD interface -----------------*/
-Sprite *Keyboard::_client = NULL;
-uint8 Keyboard::_key[0x60] = { 0 };
-uint16 Keyboard::_current = 0;
-uint16 Keyboard::_code[0x60] = {
+const uint16 Keyboard::_code[0x60] = {
0, Esc, '1', '2', '3',
'4', '5', '6', '7', '8',
'9', '0', '-', '+', BSp,
@@ -60,10 +57,12 @@ uint16 Keyboard::_code[0x60] = {
0 * 0x5F
};
-void (* Keyboard::OldKeyboard)(...);
-
Keyboard::Keyboard() {
+ _client = NULL;
+ Common::set_to(&_key[0], &_key[0x60], 0);
+ _current = 0;
+
// steal keyboard interrupt
/* TODO replace totally by scummvm handling
OldKeyboard = getvect(KEYBD_INT);