feat(console): implement OnMouseUp event handler (#101)

This commit is contained in:
Tristan 'Natrist' Cormier 2025-10-04 20:38:35 -04:00 committed by GitHub
parent f479d6ab53
commit 0b1c478f33
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 9 additions and 1 deletions

View File

@ -6,6 +6,7 @@
void PasteInInputLine(const char* inputLine);
void ResetHighlight();
void SetHighlightState(HIGHLIGHTSTATE state);
namespace {
@ -80,7 +81,10 @@ int32_t OnMouseMove(const EVENT_DATA_MOUSE* data, void* param) {
}
int32_t OnMouseUp(const EVENT_DATA_MOUSE* data, void* param) {
// TODO
if (!EventIsKeyDown(ConsoleGetHotKey()) && ConsoleGetActive()) {
SetHighlightState(HS_ENDHIGHLIGHT);
ConsoleSetResizeState(CS_NONE);
}
return 1;
}

View File

@ -93,6 +93,10 @@ void ResetHighlight() {
s_hRect = { 0.0f, 0.0f, 0.0f, 0.0f };
}
void SetHighlightState(HIGHLIGHTSTATE state) {
s_highlightState = state;
}
void PasteInInputLine(const char* inputLine) {
// TODO
}