added some kbm stuff
This commit is contained in:
1 parent
82e802873f
commit
42fd7414e4
218 files changed
+3758
-258
No files matched your search
@@ -21,6 +21,9 @@ public:
|
||||
static CRITICAL_SECTION ms_reloadSkinCS;
|
||||
static bool ms_bReloadSkinCSInitialised;
|
||||
|
||||
static CRITICAL_SECTION UIController::ms_controllerPollCS;
|
||||
static bool UIController::ms_bControllerPollCSInitialised;
|
||||
|
||||
protected:
|
||||
UIComponent_DebugUIConsole *m_uiDebugConsole;
|
||||
UIComponent_DebugUIMarketingGuide *m_uiDebugMarketingGuide;
|
||||
@@ -49,6 +52,31 @@ private:
|
||||
eFont_Korean,
|
||||
|
||||
};
|
||||
|
||||
#ifdef _WINDOWS64
|
||||
enum EControllerType
|
||||
{
|
||||
PS3,
|
||||
PS4,
|
||||
PS5,
|
||||
|
||||
XBOXONE,
|
||||
XBOX360,
|
||||
|
||||
SWITCH,
|
||||
GAMECUBE,
|
||||
|
||||
STANDARD,
|
||||
UNKNOWN,
|
||||
UNSET
|
||||
};
|
||||
|
||||
EControllerType m_LastControllerType;
|
||||
C4JThread *m_controllerPollThread;
|
||||
volatile bool m_bControllerTypeChanged;
|
||||
|
||||
static int controllerPollThreadProc(void *lpParam);
|
||||
#endif
|
||||
|
||||
// 4J-JEV: It's important that currentFont == targetFont, unless updateCurrentLanguage is going to be called.
|
||||
EFont m_eCurrentFont, m_eTargetFont;
|
||||
@@ -70,7 +98,7 @@ public:
|
||||
|
||||
private:
|
||||
// 4J-PB - ui element type for PSVita touch control
|
||||
#ifdef __PSVITA__
|
||||
#if defined(__PSVITA__) || defined(_WINDOWS64)
|
||||
|
||||
typedef struct
|
||||
{
|
||||
@@ -91,11 +119,28 @@ private:
|
||||
eLibrary_GraphicsInGame,
|
||||
eLibrary_GraphicsTooltips,
|
||||
eLibrary_GraphicsLabels,
|
||||
#ifdef _WINDOWS64
|
||||
eLibrary_ControlTooltips,
|
||||
#endif
|
||||
eLibrary_Labels,
|
||||
eLibrary_InGame,
|
||||
eLibrary_HUD,
|
||||
eLibrary_Tooltips,
|
||||
eLibrary_Default,
|
||||
#ifdef _WINDOWS64
|
||||
eLibrary_Alt_Platform,
|
||||
eLibrary_Alt_GraphicsDefault,
|
||||
eLibrary_Alt_GraphicsHUD,
|
||||
eLibrary_Alt_GraphicsInGame,
|
||||
eLibrary_Alt_GraphicsTooltips,
|
||||
eLibrary_Alt_GraphicsLabels,
|
||||
eLibrary_Alt_ControlTooltips,
|
||||
eLibrary_Alt_Labels,
|
||||
eLibrary_Alt_InGame,
|
||||
eLibrary_Alt_HUD,
|
||||
eLibrary_Alt_Tooltips,
|
||||
eLibrary_Alt_Default,
|
||||
#endif
|
||||
|
||||
eLibrary_Count,
|
||||
};
|
||||
@@ -155,19 +200,49 @@ private:
|
||||
|
||||
public:
|
||||
UIController();
|
||||
#ifdef __PSVITA__
|
||||
#if defined(__PSVITA__) || defined(_WINDOWS64)
|
||||
void TouchBoxAdd(UIControl *pControl,UIScene *pUIScene);
|
||||
bool TouchBoxHit(UIScene *pUIScene,S32 x, S32 y);
|
||||
bool IsTouchBoxUnderPoint(S32 x, S32 y);
|
||||
bool IsTouchBoxUnderPointInScene(UIScene *pUIScene, S32 x, S32 y);
|
||||
bool TouchBoxPointInScene(UIScene *pUIScene,S32 x, S32 y, int iClientW, int iClientH);
|
||||
void TouchBoxesClear(UIScene *pUIScene);
|
||||
void TouchBoxRebuild(UIScene *pUIScene);
|
||||
|
||||
void HandleTouchInput(unsigned int iPad, unsigned int key, bool bPressed, bool bRepeat, bool bReleased);
|
||||
void SendTouchInput(unsigned int iPad, unsigned int key, bool bPressed, bool bRepeat, bool bReleased);
|
||||
|
||||
bool GetTouchBoxBounds(UIControl *pControl, S32 &x1, S32 &y1, S32 &x2, S32 &y2);
|
||||
|
||||
void GetMovieMousePos(UIScene *pScene, float &fx, float &fy);
|
||||
|
||||
bool IsCraftingMenuDisplayed(int iPad);
|
||||
bool IsSkinSelectMenuDisplayed(int iPad);
|
||||
#ifdef _WINDOWS64
|
||||
bool IsControllerMode() { return m_bControllerMode; }
|
||||
int GetDefaultFocusId(UIScene *pScene);
|
||||
#endif
|
||||
|
||||
private:
|
||||
void TouchBoxAdd(UIControl *pControl,EUIGroup eUIGroup,EUILayer eUILayer,EUIScene eUIscene, UIControl *pMainPanelControl);
|
||||
UIELEMENT *m_ActiveUIElement;
|
||||
UIELEMENT *m_HighlightedUIElement;
|
||||
|
||||
bool wasFocused;
|
||||
|
||||
UIScene *m_pLastHoverScene;
|
||||
int m_iLastHoverId;
|
||||
bool m_bHoverFresh;
|
||||
int m_iFreshMouseX;
|
||||
int m_iFreshMouseY;
|
||||
__int64 m_hoverFreshUntilMs;
|
||||
UIControl *m_pLastListFocusControl;
|
||||
int m_iLastListFocusX;
|
||||
int m_iLastListFocusY;
|
||||
bool m_bControllerMode;
|
||||
int m_iLastDeviceMouseX;
|
||||
int m_iLastDeviceMouseY;
|
||||
void UpdateInputDeviceMode();
|
||||
#endif
|
||||
|
||||
protected:
|
||||
@@ -199,12 +274,18 @@ public:
|
||||
public:
|
||||
// TICKING
|
||||
virtual void tick();
|
||||
#ifdef _WINDOWS64
|
||||
wstring GetControlTooltipsPath(EControllerType ControllerType = EControllerType::UNSET);
|
||||
EControllerType GetControllerType(const char* controllerType);
|
||||
void fetchControlTooltipSWF();
|
||||
#endif
|
||||
|
||||
private:
|
||||
void loadSkins();
|
||||
IggyLibrary loadSkin(const wstring &skinPath, const wstring &skinName);
|
||||
|
||||
public:
|
||||
void reloadSingleSkin(ELibraries lib, const wstring &skinPath, const wstring &skinName);
|
||||
void ReloadSkin();
|
||||
virtual void StartReloadSkinThread();
|
||||
virtual bool IsReloadingSkin();
|
||||
|
||||
Reference in new issue
Block a user