PAD: Fix variable initializations.

Codacy Warning: Variable 'variable' is assigned in constructor body. Consider performing initialization in initialization list
This commit is contained in:
lightningterror 2022-08-24 03:45:09 +02:00
parent 97aaf3ef9b
commit 060a8f6345
3 changed files with 8 additions and 10 deletions

View File

@ -18,9 +18,9 @@
GamepadConfiguration::GamepadConfiguration(int pad, wxWindow* parent)
: wxDialog(parent, wxID_ANY, _T("Gamepad"), wxDefaultPosition, wxDefaultSize,
wxSYSTEM_MENU | wxCAPTION | wxCLOSE_BOX | wxCLIP_CHILDREN)
{
m_pad_id = pad;
, m_pad_id(pad)
{
wxBoxSizer* gamepad_box = new wxBoxSizer(wxVERTICAL);
wxArrayString choices;

View File

@ -137,9 +137,9 @@ public:
GUID guidInstance;
DirectInputDevice(DeviceType type, IDirectInputDevice8* did, wchar_t* displayName, wchar_t* instanceID, wchar_t* productID, GUID guid)
: Device(DI, type, displayName, instanceID, productID)
, guidInstance(guid)
{
diEffects = 0;
guidInstance = guid;
this->did = 0;
did->EnumEffects(EnumEffectsCallback, this, DIEFT_ALL);
did->EnumObjects(EnumDeviceObjectsCallback, this, DIDFT_ALL);

View File

@ -18,14 +18,12 @@
#include "WndProcEater.h"
WndProcEater::WndProcEater()
: hWndEaten(0)
, eatenWndProc(0)
, extraProcs(0)
, numExtraProcs(0)
, hMutex(CreateMutex(0, 0, L"PAD"))
{
hWndEaten = 0;
eatenWndProc = 0;
extraProcs = 0;
numExtraProcs = 0;
hMutex = CreateMutex(0, 0, L"PAD");
}
WndProcEater::~WndProcEater() throw()