2020-03-24 08:38 AM
Is there a possibility to handle events which are in specific area, i.e. I would like to know when and how user drags over texture mapper area to rotate it accordingly.
Thank You,
Sławek
Solved! Go to Solution.
2020-03-31 07:38 AM
You can override the handleDragEvent function for your view and check if the coordinates intersect with various elements on screen. Here's some pseudocode
void MyView::handleDragEvent(const DragEvent& evt)
{
int16_t newX = evt.getNewX();
int16_t newY = evt.getNewY();
//Check for intersection
if(intersects)
{
element.handleDragEvent(evt);
}
...
}
2020-03-31 07:38 AM
You can override the handleDragEvent function for your view and check if the coordinates intersect with various elements on screen. Here's some pseudocode
void MyView::handleDragEvent(const DragEvent& evt)
{
int16_t newX = evt.getNewX();
int16_t newY = evt.getNewY();
//Check for intersection
if(intersects)
{
element.handleDragEvent(evt);
}
...
}