mirror of
https://github.com/isledecomp/isle.git
synced 2025-10-23 00:14:22 +00:00
implement LegoInputManager::ProcessOneEvent (#498)
* push changes * fix * Match * Rename functions * Space * Fix GetPresenterAt --------- Co-authored-by: Christian Semmler <mail@csemmler.com>
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
#ifndef LEGOCONTROLMANAGER_H
|
||||
#define LEGOCONTROLMANAGER_H
|
||||
|
||||
#include "legoeventnotificationparam.h"
|
||||
#include "mxcore.h"
|
||||
#include "mxpresenterlist.h"
|
||||
|
||||
@@ -28,13 +29,20 @@ public:
|
||||
void FUN_10028df0(MxPresenterList* p_presenterList);
|
||||
void Register(MxCore* p_listener);
|
||||
void Unregister(MxCore* p_listener);
|
||||
MxBool FUN_10029210(LegoEventNotificationParam& p_param, MxPresenter* p_presenter);
|
||||
void FUN_100293c0(undefined4, const char*, undefined2);
|
||||
|
||||
inline undefined4 GetUnknown0x0c() { return m_unk0x0c; }
|
||||
inline undefined GetUnknown0x10() { return m_unk0x10; }
|
||||
|
||||
// SYNTHETIC: LEGO1 0x10028d40
|
||||
// LegoControlManager::`scalar deleting destructor'
|
||||
|
||||
private:
|
||||
undefined m_padding0x08[0x58]; // 0x08
|
||||
undefined4 m_unk0x08; // 0x08
|
||||
undefined4 m_unk0x0c; // 0x0c
|
||||
undefined m_unk0x10; // 0x10
|
||||
undefined m_padding0x14[0x4c]; // 0x14
|
||||
};
|
||||
|
||||
#endif // LEGOCONTROLMANAGER_H
|
||||
|
@@ -3,6 +3,7 @@
|
||||
|
||||
#include "mxnotificationparam.h"
|
||||
#include "mxtypes.h"
|
||||
#include "roi/legoroi.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
@@ -15,7 +16,7 @@ public:
|
||||
{
|
||||
LegoEventNotificationParam* clone =
|
||||
new LegoEventNotificationParam(m_type, m_sender, m_modifier, m_x, m_y, m_key);
|
||||
clone->m_unk0x1c = m_unk0x1c;
|
||||
clone->m_roi = m_roi;
|
||||
return clone;
|
||||
}; // vtable+0x4
|
||||
|
||||
@@ -28,7 +29,7 @@ public:
|
||||
MxS32 p_y,
|
||||
MxU8 p_key
|
||||
)
|
||||
: MxNotificationParam(p_type, p_sender), m_modifier(p_modifier), m_x(p_x), m_y(p_y), m_key(p_key), m_unk0x1c(0)
|
||||
: MxNotificationParam(p_type, p_sender), m_modifier(p_modifier), m_x(p_x), m_y(p_y), m_key(p_key), m_roi(NULL)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -37,12 +38,14 @@ public:
|
||||
inline MxS32 GetX() const { return m_x; }
|
||||
inline MxS32 GetY() const { return m_y; }
|
||||
|
||||
inline void SetROI(LegoROI* p_roi) { m_roi = p_roi; }
|
||||
|
||||
protected:
|
||||
MxU8 m_modifier; // 0x0c
|
||||
MxS32 m_x; // 0x10
|
||||
MxS32 m_y; // 0x14
|
||||
MxU8 m_key; // 0x18
|
||||
MxU32 m_unk0x1c; // 0x1c
|
||||
LegoROI* m_roi; // 0x1c
|
||||
};
|
||||
|
||||
// SYNTHETIC: LEGO1 0x10028770
|
||||
|
@@ -83,8 +83,8 @@ public:
|
||||
void ReleaseDX();
|
||||
MxResult GetJoystickId();
|
||||
MxResult GetJoystickState(MxU32* p_joystickX, MxU32* p_joystickY, DWORD* p_buttonsState, MxU32* p_povPosition);
|
||||
void SetTimer();
|
||||
void KillTimer();
|
||||
void StartAutoDragTimer();
|
||||
void StopAutoDragTimer();
|
||||
void EnableInputProcessing();
|
||||
void SetCamera(LegoCameraController* p_camera);
|
||||
void ClearCamera();
|
||||
@@ -109,6 +109,7 @@ public:
|
||||
|
||||
void ProcessEvents();
|
||||
MxBool ProcessOneEvent(LegoEventNotificationParam& p_param);
|
||||
MxBool FUN_1005cdf0(LegoEventNotificationParam& p_param);
|
||||
|
||||
// SYNTHETIC: LEGO1 0x1005b8d0
|
||||
// LegoInputManager::`scalar deleting destructor'
|
||||
@@ -122,8 +123,8 @@ private:
|
||||
undefined4 m_unk0x6c; // 0x6c
|
||||
undefined4 m_unk0x70; // 0x70
|
||||
undefined4 m_unk0x74; // 0x74
|
||||
UINT m_timer; // 0x78
|
||||
UINT m_timeout; // 0x7c
|
||||
UINT m_autoDragTimerID; // 0x78
|
||||
UINT m_autoDragTime; // 0x7c
|
||||
undefined m_unk0x80; // 0x80
|
||||
undefined m_unk0x81; // 0x81
|
||||
LegoControlManager* m_controlManager; // 0x84
|
||||
|
@@ -31,7 +31,8 @@ public:
|
||||
override; // vtable+0x2c
|
||||
virtual MxResult RealizePalette(MxPalette*) override; // vtable+0x30
|
||||
virtual void UpdateView(MxU32 p_x, MxU32 p_y, MxU32 p_width, MxU32 p_height) override; // vtable+0x34
|
||||
virtual void VTable0x38(undefined4, undefined4); // vtable+0x38
|
||||
virtual MxPresenter* GetPresenterAt(MxS32 p_x, MxS32 p_y); // vtable+0x38
|
||||
|
||||
// FUNCTION: LEGO1 0x1007ab10
|
||||
virtual LegoUnknown100d9d00* VTable0x3c() { return m_unk0x100d9d00; } // vtable+0x3c
|
||||
|
||||
|
Reference in New Issue
Block a user