Let buttons catch touchStart

Resolves https://github.com/EdgeTX/edgetx/issues/1087
This commit is contained in:
Peter Feerick
2021-12-08 21:46:04 +10:00
committed by Peter Feerick
parent 929847209d
commit a557b5d2fe
2 changed files with 9 additions and 0 deletions
+8
View File
@@ -47,6 +47,14 @@ void Button::onEvent(event_t event)
}
#endif
#if defined(HARDWARE_TOUCH)
bool Button::onTouchStart(coord_t x, coord_t y)
{
Window::onTouchStart(x, y);
return true;
}
#endif
#if defined(HARDWARE_TOUCH)
bool Button::onTouchEnd(coord_t x, coord_t y)
{
+1
View File
@@ -74,6 +74,7 @@ class Button: public FormField
#endif
#if defined(HARDWARE_TOUCH)
bool onTouchStart(coord_t x, coord_t y) override;
bool onTouchEnd(coord_t x, coord_t y) override;
#endif