This first one I created a widget button that goes with my widget for level selection. Then I built a pretty button to put on top.
Item#1:
local doneButton = widget.newButton({
id = “button1”,
label = “Cancel”,
onEvent = handleCancelButtonEvent
})
doneButton.x = display.contentCenterX; doneButton.y = display.contentCenterY+380
sceneGroup:insert( doneButton )
cancelBtn = display.newImage(“Images/cancelBtn.png”)
cancelBtn.isVisible = true
cancelBtn:scale(2, 2)
sceneGroup:insert(cancelBtn)
cancelBtn.x = display.contentCenterX; cancelBtn.y = display.contentCenterY+400
Item#2: My other buttons are like this
-----------------------------------------------------------------------------
– EVENT FOR PRESSING THE PLAY BUTTON
function startGame(event)
playBtn.isActive = true
composer.gotoScene(“levelTracker”, “fade”, 400)
return true
end
playBtn = display.newImage(“Images/PLAYmenu2.png”)
playBtn.x=display.contentCenterX; playBtn.y=display.contentCenterY + 250
playBtn:scale(1.3, 1.3)
playBtn.isActive = true
onRelease = startGame
sceneGroup:insert(playBtn)
It’s like I push and push and nothing …but on others it works fine. When I’m doing it on the computer with the mouse I don’t have any problems either.
Thanks,
Lori