PILog ready to use

This commit is contained in:
2024-09-19 17:26:58 +03:00
parent aa963a4bda
commit 4acab04895
4 changed files with 53 additions and 14 deletions

View File

@@ -220,7 +220,6 @@ void PIKbdListener::readKeyboard() {
#ifdef WINDOWS
INPUT_RECORD ir;
ReadConsoleInput(PRIVATE->hIn, &ir, 1, &(PRIVATE->ret));
// piCout << ir.EventType;
switch (ir.EventType) {
case KEY_EVENT: {
KEY_EVENT_RECORD ker = ir.Event.KeyEvent;
@@ -542,6 +541,11 @@ void PIKbdListener::readKeyboard() {
}
void PIKbdListener::stop() {
PIThread::stop();
}
void PIKbdListener::end() {
// cout << "list end" << endl;
#ifdef WINDOWS

View File

@@ -180,6 +180,8 @@ public:
void readKeyboard();
void stop();
//! Returns if keyboard listening is active (not running!)
bool isActive() { return is_active; }