We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8cb9027 commit 59398dfCopy full SHA for 59398df
src/devices/screen.cpp
@@ -40,11 +40,11 @@ void Screen::on_touched(
40
// TODO: Determine thread safety? (What happens if task A calls this, and while touch_task is
41
// being constructed, task B preempts it and calls this again?)
42
static pros::Task touch_task([] {
43
- while (true) {
44
- const auto touch = Screen::get_last_touch();
+ while (true) {
+ const auto touch = Screen::get_last_touch();
45
const auto state = touch.state;
46
- static Screen::TouchEvent::State prev_state = state;
47
- static size_t prev_time = pros::millis();
+ static Screen::TouchEvent::State prev_state = state;
+ static uint32_t prev_time = pros::millis();
48
49
if (prev_state != state)
50
for (const auto& listener : listeners)
0 commit comments