Skip to content

Commit

Permalink
Merge pull request #625 from hb020/reenable-idle-scripts
Browse files Browse the repository at this point in the history
re-enable idle scripts
  • Loading branch information
fvanroie authored Jan 28, 2024
2 parents 1cb1448 + c190cf9 commit 54ca244
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/hasp/hasp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -121,18 +121,21 @@ HASP_ATTRIBUTE_FAST_MEM void hasp_update_sleep_state()
gui_hide_pointer(true);
hasp_sleep_state = HASP_SLEEP_LONG;
dispatch_idle_state(HASP_SLEEP_LONG);
dispatch_run_script(NULL, "L:/idle_long.cmd", TAG_HASP);
}
} else if(sleepTimeShort > 0 && idle >= sleepTimeShort) {
if(hasp_sleep_state != HASP_SLEEP_SHORT) {
gui_hide_pointer(true);
hasp_sleep_state = HASP_SLEEP_SHORT;
dispatch_idle_state(HASP_SLEEP_SHORT);
dispatch_run_script(NULL, "L:/idle_short.cmd", TAG_HASP);
}
} else {
if(hasp_sleep_state != HASP_SLEEP_OFF) {
gui_hide_pointer(false);
hasp_sleep_state = HASP_SLEEP_OFF;
dispatch_idle_state(HASP_SLEEP_OFF);
dispatch_run_script(NULL, "L:/idle_off.cmd", TAG_HASP);
}
}
}
Expand Down

0 comments on commit 54ca244

Please sign in to comment.