When ever I click on a new button widget the subject message is shown in the console.
I thought it might be an early release ‘bug’ but it still occurs on latest free download.
No major problem (i hope) but just wondering what have I missed/done incorrectly to cause the warnings.
Here is the button code
backButton = widget.newButton
{
left = 10,
– width=toolBarHeight*0.99,
height=navBarHeight*0.70,
width=navBarHeight,
top = NavBar.y+ navBarHeight*0.15,
id=1,
defaultFile =“Images/backbtn.png”,
overFile=“Images/backbtn over.png”,
fontSize=10,–click message size
labelAlign=right,
onEvent = onButtonEvent
}
local function onButtonEvent( event )
local phase = event.phase
local target = event.target
if ( “began” == phase ) then
if (2 == target.id ) then
target:setLabel( "Settings " ) --set a new label
elseif (3 == target.id ) then
target:setLabel( "Download " ) --set a new label
elseif (1 == target.id ) then
end
elseif ( “ended” == phase ) then
target:setLabel( target.baseLabel ) --reset the label
if (1 == target.id ) then
GoToDashboard()
end
if (2 == target.id ) then
GoToSettings()
end
end
return
end