2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-09 05:47:42 +00:00

Initial mouse events for pause screen

This commit is contained in:
Jack Andersen
2019-01-20 18:10:34 -10:00
parent 47c6b5cba8
commit f3f9924309
25 changed files with 620 additions and 176 deletions

View File

@@ -1,5 +1,7 @@
#pragma once
#include "boo/IWindow.hpp"
namespace urde {
struct CFinalInput;
@@ -100,6 +102,14 @@ public:
MAX // default case
};
enum class EKBMFunctionList {
None,
KeyPress,
SpecialKeyPress = 259,
MousePress = 285,
MAX = 291 /* Provide space for keys/buttons within base actions */
};
static void SetCommandFiltered(ECommands cmd, bool filtered);
static void ResetCommandFilters();
static bool GetPressInput(ECommands cmd, const CFinalInput& input);
@@ -109,4 +119,19 @@ public:
static const char* GetDescriptionForFunction(EFunctionList func);
};
constexpr ControlMapper::EKBMFunctionList operator+(ControlMapper::EKBMFunctionList a, char b) {
using T = std::underlying_type_t<ControlMapper::EKBMFunctionList>;
return ControlMapper::EKBMFunctionList(static_cast<T>(a) + static_cast<T>(b));
}
constexpr ControlMapper::EKBMFunctionList operator+(ControlMapper::EKBMFunctionList a, boo::ESpecialKey b) {
using T = std::underlying_type_t<ControlMapper::EKBMFunctionList>;
return ControlMapper::EKBMFunctionList(static_cast<T>(a) + static_cast<T>(b));
}
constexpr ControlMapper::EKBMFunctionList operator+(ControlMapper::EKBMFunctionList a, boo::EMouseButton b) {
using T = std::underlying_type_t<ControlMapper::EKBMFunctionList>;
return ControlMapper::EKBMFunctionList(static_cast<T>(a) + static_cast<T>(b));
}
} // namespace urde