logo
down
shadow

How to add touch and scroll event on a button on a top of scroll view Corona?


How to add touch and scroll event on a button on a top of scroll view Corona?

By : Jay Leo
Date : November 19 2020, 03:59 PM
seems to work fine I have solved my problem using takefocus method inside the button listener with this code
code :
if ( phase == "moved" ) then
    local dy = math.abs( ( event.y - event.yStart ) )
    -- If the touch on the button has moved more than 10 pixels,
    -- pass focus back to the scroll view so it can continue scrolling
    if ( dy > 10 ) then
        scrollView:takeFocus( event )
    end
end


Share : facebook icon twitter icon
I have a UI Scroll View with UIButtons on top. How do i make it scroll when they touch and drag the buttons?

I have a UI Scroll View with UIButtons on top. How do i make it scroll when they touch and drag the buttons?


By : user2596645
Date : March 29 2020, 07:55 AM
Does that help A touch-down-drag is a completely different event. Apple doesn't support this directly—you'd have to code it in—start tracking the touches using the gesture responders as soon as a touch-down-inside is detected, then scroll the same amount, and stop scrolling at a touch-up-outside (or inside). This would most likely fall under the category of unusual use of interface elements, and could very well get you rejected.
css scroll/touch slide view - how to use -ms-scroll-snap or the like?

css scroll/touch slide view - how to use -ms-scroll-snap or the like?


By : Louie
Date : March 29 2020, 07:55 AM
UIScrollView with UIButtons - Scroll View won't scroll when touch began on button

UIScrollView with UIButtons - Scroll View won't scroll when touch began on button


By : Raviraj
Date : March 29 2020, 07:55 AM
hop of those help? I ended up creating a subclass of UIScrollView and set it's cancelContentTouches value to TRUE and my problem was solved
Last button in my scroll view cannot register touch

Last button in my scroll view cannot register touch


By : Vivien Neault
Date : March 29 2020, 07:55 AM
fixed the issue. Will look into that further Please check your views using view debugger and ensure that your button is inside the scrollview. Sometimes if you adjust the content size of scroll view the button could be gone out of the scroll view.
automatic scroll - a scroll view on Touch of textField - iPhone

automatic scroll - a scroll view on Touch of textField - iPhone


By : user3791895
Date : March 29 2020, 07:55 AM
may help you . You can use the method - (void)setContentOffset:(CGPoint)contentOffset animated:(BOOL)animated in UIScrollView, this should scroll to the offset of the point you give it, you will need to figure out the offset through code
shadow
Privacy Policy - Terms - Contact Us © ourworld-yourmove.org