Update nemirtingas overlay.

This commit is contained in:
Mr_Goldberg 2022-08-13 14:32:43 -04:00
parent b72b4da8fb
commit 743a810463
No known key found for this signature in database
GPG key ID: 8597D87419DEF278
22 changed files with 235 additions and 79 deletions

View file

@ -41,6 +41,12 @@ private:
bool _Initialized;
Window _GameWnd;
// In (bool): Is toggle wanted
// Out(bool): Is the overlay visible, if true, inputs will be disabled
std::function<bool(bool)> _KeyCombinationCallback;
std::set<uint32_t> _NativeKeyCombination;
bool _KeyCombinationPushed;
// Functions
X11_Hook();
int _CheckForOverlay(Display *d, int num_events);
@ -52,8 +58,6 @@ private:
static int MyXEventsQueued(Display * display, int mode);
static int MyXPending(Display* display);
std::function<bool(bool)> _KeyCombinationCallback;
public:
std::string LibraryName;
@ -65,7 +69,7 @@ public:
Window GetGameWnd() const{ return _GameWnd; }
bool StartHook(std::function<bool(bool)>& key_combination_callback);
bool StartHook(std::function<bool(bool)>& key_combination_callback, std::set<ingame_overlay::ToggleKey> const& toggle_keys);
static X11_Hook* Inst();
virtual std::string GetLibraryName() const;
};