2022-02-12 01:16 AM
Hello,
i have a swipe container to have the nice animation between "Screens" without scolling some fix containers.
The problem i have is that i have multiple flexbuttons (for changing pages when clicked) inside the swipe container. If i try to swipe the screen on top of the flex-buttons it will not work.
Means, i need a "free space" where i am able to swipe.
Is there any solution or any idea for a workaround?
On my smartphone i can also swipe when i start swiping on an icon of an app and don't need to start swipe on the background :)
Thanks a lot.
Solved! Go to Solution.
2022-02-15 11:26 PM
Hi,
Transfer your ClickEvent of button into swipeContianer.
void XXXXX::clickActionButtonHandler(const CustomButton& _btn, const ClickEvent& evt)
{
if (&_btn == &customButton1)
{
mySwipeContainer.handleClickEvent(evt);
if (mySwipeContainer.isAnimating())
return;
}
}
Transfer your DragEventof button into swipeContianer.
void XXXXX::dragActionButtonHandler(const CustomButton& _btn, const DragEvent& evt)
{
if (&_btn == &customButton1)
{
mySwipeContainer.handleDragEvent(evt);
customButton1.toReleaseState();//change pressed state when drag
customButton1.invalidate();
}
}
2022-02-15 11:26 PM
Hi,
Transfer your ClickEvent of button into swipeContianer.
void XXXXX::clickActionButtonHandler(const CustomButton& _btn, const ClickEvent& evt)
{
if (&_btn == &customButton1)
{
mySwipeContainer.handleClickEvent(evt);
if (mySwipeContainer.isAnimating())
return;
}
}
Transfer your DragEventof button into swipeContianer.
void XXXXX::dragActionButtonHandler(const CustomButton& _btn, const DragEvent& evt)
{
if (&_btn == &customButton1)
{
mySwipeContainer.handleDragEvent(evt);
customButton1.toReleaseState();//change pressed state when drag
customButton1.invalidate();
}
}
2022-02-16 02:47 AM
Thank you very much.
Thats sounds logical and i will test it as soon as i have time.