| 6 | #include "script_button.h" |
| 7 | |
| 8 | void ScriptButton::press() |
| 9 | { |
| 10 | if (!pressed) { |
| 11 | pressed = true; |
| 12 | |
| 13 | // The count will max out at 255, but it won't roll over to 0. |
| 14 | if (count < std::numeric_limits<uint8_t>::max()) { |
| 15 | count++; |
| 16 | } |
| 17 | } |
| 18 | } |
| 19 | |
| 20 | void ScriptButton::release() |
| 21 | { |
no outgoing calls
no test coverage detected