openMSX
Main Page
Namespaces
Classes
Files
File List
File Members
input
MagicKey.cc
Go to the documentation of this file.
1
#include "
MagicKey.hh
"
2
#include "
serialize.hh
"
3
#include "
serialize_meta.hh
"
4
5
namespace
openmsx {
6
7
// Pluggable
8
const
std::string&
MagicKey::getName
()
const
9
{
10
static
const
std::string NAME =
"magic-key"
;
11
return
NAME;
12
}
13
14
string_ref
MagicKey::getDescription
()
const
15
{
16
return
"Dongle used by some Japanese games to enable cheat mode"
;
17
}
18
19
void
MagicKey::plugHelper
(
Connector
&
/*connector*/
,
EmuTime::param
/*time*/
)
20
{
21
}
22
23
void
MagicKey::unplugHelper
(
EmuTime::param
/*time*/
)
24
{
25
}
26
27
28
// JoystickDevice
29
byte
MagicKey::read
(
EmuTime::param
/*time*/
)
30
{
31
return
JOY_BUTTONB
|
JOY_BUTTONA
|
JOY_RIGHT
|
JOY_LEFT
;
32
}
33
34
void
MagicKey::write
(
byte
/*value*/
,
EmuTime::param
/*time*/
)
35
{
36
}
37
38
39
template
<
typename
Archive>
40
void
MagicKey::serialize
(Archive&
/*ar*/
,
unsigned
/*version*/
)
41
{
42
}
43
INSTANTIATE_SERIALIZE_METHODS
(
MagicKey
);
44
REGISTER_POLYMORPHIC_INITIALIZER
(
Pluggable
,
MagicKey
,
"MagicKey"
);
45
46
}
// namespace openmsx
Generated on Mon May 20 2013 12:16:58 for openMSX by
1.8.1.2