Thanks for looking at my request. I'm using LC 5, with iOS and Android. In my current iOS project I want to implement a nice 'swipe' catalog, with an image/item on each card, perhaps 10 cards in total (that could be a group?) that contain the products. The other cards do not contain products (login, register, etc.).
So, I use the example code to implement the 'swipe' technique:
Code: Select all
# the event id and initial swipe time and position
local sTouchId, sInitTime, sInitX
# maximum swipe time in millisecs
local sSwipeTime
# minimum swipe distance
local sSwipeDistance
on openStack
# set up swipe values - experiment with these for required effect
put 500 into sSwipeTime
put 150 into sSwipeDistance
end openStack
on touchMove pId, pX, pY
if pId <> sTouchId then
# record initial values for start of swipe
put pId into sTouchId
put the millisecs into sInitTime
put pX into sInitX
end if
# check the action was fast enough for a swipe
if the millisecs - sInitTime <= sSwipeTime then
# check we have covered enough distance
put pX - sInitX into tDistanceX
if abs(tDistanceX) > sSwipeDistance then
if tDistanceX < 0 then
# finger is swiping left
send "swipeLeft" to me in 0 millisecs
else
# finger is swiping right
send "swipeRight" to me in 0 millisecs
end if
end if
end if
end touchMove
command swipeLeft
visual effect scroll left normal
go prev card
end swipeLeft
command swipeRight
visual effect scroll right normal
go next card
end swipeRight
What I want to achieve is allowing only the 'Product' Cards to be 'swiped' left or right.
Is there a way to 'Group' together a range or group of Cards in a Stack?
And then am I able to restrict which Cards are 'swipeable' (is that even a word??)?
Thanks again for your kind understanding and patience with a noob.
Regards,
Ed
Icon Visual Marketing
Camden, NSW