The scroller problem - The page is missing 1/3
Posted: Sat Nov 16, 2013 11:55 pm
HI,this is a photo album that is need horizontal image scroller. I have already created a scroller. However, the last page of photo is missing 1/3 on right hand side.
This is the code ↓
Is there wrong in this code? How to fix this problem?
I'm a bit under pressure here to get this Android version wrapped asap so I'd really appreciate any help. Thanks!
This is the code ↓
Code: Select all
local sScrollerID
on preOpenCard
local tScrollerRect, tContentRect
if environment() is not "mobile" then exit preOpenCard
put the rect of group "cards" into tScrollerRect
mobileControlCreate "scroller", "loremScroll"
put the result into sScrollerID
mobileControlSet "loremScroll", "rect", tScrollerRect
mobileControlSet "loremScroll", "contentRect", "0,0,1600,402"
mobileControlSet "loremScroll", "visible", true
mobileControlSet "loremScroll", "scrollingEnabled", true
mobileControlSet "loremScroll", "hIndicator", false
mobileControlSet "loremScroll", "hscroll", 0
end preOpenCard
on closeCard
// Delete the scroller
if environment() is not "mobile" then exit closeCard
mobileControlDelete sScrollerID
end closeCard
on scrollerDidScroll hOffset, vOffset
// When the user scrolls move the displayed content
set the hScroll of group "cards" to hOffset
end scrollerDidScroll
I'm a bit under pressure here to get this Android version wrapped asap so I'd really appreciate any help. Thanks!