Hi
We are creating a slider with a custom imageSheet. On the simulator (Windows and iOS) our custom slider is displayed properly. On the device on the other hand a strange blue pattern is displayed on Android and nothing on iOS.
Below you will find the code. Do we need to setup the theme ? If so, why ? as on the simulator it is working and based on the slider API, we provide the imageSheet.
Please help.
– Image sheet options and declaration
local options = {
frames = {
{ x=0, y=0, width=16, height=35 },
{ x=40, y=0, width=16, height=35 },
{ x=80, y=0, width=16, height=35 },
{ x=124, y=0, width=16, height=35 },
{ x=168, y=0, width=35, height=35 }
},
sheetContentWidth = 203,
sheetContentHeight = 35
}
local sliderSheet = graphics.newImageSheet( “sliderSheet.png”, options )
– Create the widget
slider = widget.newSlider
{
sheet = sliderSheet,
leftFrame = 1,
middleFrame = 2,
rightFrame = 3,
fillFrame = 4,
frameWidth = 16,
frameHeight = 35,
handleFrame = 5,
handleWidth = 35,
handleHeight = 35,
top = screen.topBar + 4,
left = screen.x + 10,
orientation = “horizontal”,
width = screen.rw - 20,
listener = sliderListener
}
group:insert( slider )