Remove redundant variable.

This commit is contained in:
Stephen Anthony 2019-08-15 07:59:54 -02:30
parent cb5a4e210c
commit 22b4f36bbc
3 changed files with 4 additions and 6 deletions

View File

@ -31,10 +31,9 @@ static constexpr char CTRL_DELIM = '^';
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
PhysicalJoystickHandler::PhysicalJoystickHandler( PhysicalJoystickHandler::PhysicalJoystickHandler(
OSystem& system, EventHandler& handler, Event& event) OSystem& system, EventHandler& handler)
: myOSystem(system), : myOSystem(system),
myHandler(handler), myHandler(handler)
myEvent(event)
{ {
Int32 version = myOSystem.settings().getInt("event_ver"); Int32 version = myOSystem.settings().getInt("event_ver");
// Load previously saved joystick mapping (if any) from settings // Load previously saved joystick mapping (if any) from settings

View File

@ -61,7 +61,7 @@ class PhysicalJoystickHandler
}; };
public: public:
PhysicalJoystickHandler(OSystem& system, EventHandler& handler, Event& event); PhysicalJoystickHandler(OSystem& system, EventHandler& handler);
/** Return stick ID on success, -1 on failure. */ /** Return stick ID on success, -1 on failure. */
int add(PhysicalJoystickPtr stick); int add(PhysicalJoystickPtr stick);
@ -112,7 +112,6 @@ class PhysicalJoystickHandler
OSystem& myOSystem; OSystem& myOSystem;
EventHandler& myHandler; EventHandler& myHandler;
Event& myEvent;
// Contains all joysticks that Stella knows about, indexed by name // Contains all joysticks that Stella knows about, indexed by name
StickDatabase myDatabase; StickDatabase myDatabase;

View File

@ -73,7 +73,7 @@ EventHandler::EventHandler(OSystem& osystem)
myPKeyHandler = make_unique<PhysicalKeyboardHandler>(osystem, *this); myPKeyHandler = make_unique<PhysicalKeyboardHandler>(osystem, *this);
// Create joystick handler (to handle all physical joystick functionality) // Create joystick handler (to handle all physical joystick functionality)
myPJoyHandler = make_unique<PhysicalJoystickHandler>(osystem, *this, myEvent); myPJoyHandler = make_unique<PhysicalJoystickHandler>(osystem, *this);
// Erase the 'combo' array // Erase the 'combo' array
for(int i = 0; i < COMBO_SIZE; ++i) for(int i = 0; i < COMBO_SIZE; ++i)