Remove some redundant code

pull/2783/head
Andrei Kortunov 5 years ago
parent 3328775eff
commit 85f91a7de8

@ -2,33 +2,16 @@
#include <osgViewer/ViewerEventHandlers>
#include <MyGUI_InputManager.h>
#include <MyGUI_Widget.h>
#include <MyGUI_Button.h>
#include <MyGUI_EditBox.h>
#include <SDL_version.h>
#include <components/debug/debuglog.hpp>
#include <components/sdlutil/sdlinputwrapper.hpp>
#include <components/esm/esmwriter.hpp>
#include <components/esm/esmreader.hpp>
#include <components/esm/controlsstate.hpp>
#include "../mwbase/world.hpp"
#include "../mwbase/windowmanager.hpp"
#include "../mwbase/statemanager.hpp"
#include "../mwbase/environment.hpp"
#include "../mwbase/mechanicsmanager.hpp"
#include "../mwworld/player.hpp"
#include "../mwworld/class.hpp"
#include "../mwworld/inventorystore.hpp"
#include "../mwworld/esmstore.hpp"
#include "../mwmechanics/npcstats.hpp"
#include "../mwmechanics/actorutil.hpp"
#include "actionmanager.hpp"
#include "bindingsmanager.hpp"
#include "controllermanager.hpp"
@ -58,7 +41,7 @@ namespace MWInput
mActionManager = new ActionManager(mBindingsManager, screenCaptureOperation, viewer, screenCaptureHandler);
mKeyboardManager = new KeyboardManager(mBindingsManager, mActionManager);
mKeyboardManager = new KeyboardManager(mBindingsManager);
mInputWrapper->setKeyboardEventCallback(mKeyboardManager);
mMouseManager = new MouseManager(mBindingsManager, mInputWrapper, window);

@ -1,19 +1,16 @@
#ifndef MWINPUT_MWINPUTMANAGERIMP_H
#define MWINPUT_MWINPUTMANAGERIMP_H
#include "../mwgui/mode.hpp"
#include <SDL_sensor.h>
#include <osg/ref_ptr>
#include <osgViewer/ViewerEventHandlers>
#include <components/settings/settings.hpp>
#include <components/files/configurationmanager.hpp>
#include <components/sdlutil/events.hpp>
#include "../mwbase/inputmanager.hpp"
#include "../mwgui/mode.hpp"
#include "actions.hpp"
namespace MWInput
@ -37,11 +34,6 @@ namespace MWBase
class WindowManager;
}
namespace Files
{
struct ConfigurationManager;
}
namespace SDLUtil
{
class InputWrapper;

@ -4,22 +4,18 @@
#include "../mwbase/environment.hpp"
#include "../mwbase/inputmanager.hpp"
#include "../mwbase/statemanager.hpp"
#include "../mwbase/windowmanager.hpp"
#include "../mwbase/world.hpp"
#include "../mwworld/player.hpp"
#include "actionmanager.hpp"
#include "actions.hpp"
#include "bindingsmanager.hpp"
#include "sdlmappings.hpp"
namespace MWInput
{
KeyboardManager::KeyboardManager(BindingsManager* bindingsManager, ActionManager* actionManager)
KeyboardManager::KeyboardManager(BindingsManager* bindingsManager)
: mBindingsManager(bindingsManager)
, mActionManager(actionManager)
, mControlsDisabled(false)
{
}

@ -4,20 +4,14 @@
#include <components/settings/settings.hpp>
#include <components/sdlutil/events.hpp>
namespace SDLUtil
{
class InputWrapper;
}
namespace MWInput
{
class ActionManager;
class BindingsManager;
class KeyboardManager : public SDLUtil::KeyListener
{
public:
KeyboardManager(BindingsManager* bindingsManager, ActionManager* actionManager);
KeyboardManager(BindingsManager* bindingsManager);
virtual ~KeyboardManager() = default;
@ -30,8 +24,6 @@ namespace MWInput
private:
BindingsManager* mBindingsManager;
ActionManager* mActionManager;
bool mControlsDisabled;
};
}

Loading…
Cancel
Save