Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

how to i install widget in zerobrane
Started by neo2morris Dec 22 2016 02:42 AM

1 reply to this topic
[TOPIC CONTROLS]
This topic has been archived. This means that you cannot reply to this topic.
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

neo2morris

[GLOBAL: userInfoPane.html]
neo2morris
  • Observer

  • 22 posts
  • Corona SDK

this what i have done so far but with my zerobrane text editor there sems to be a problem with my widget any help will be greatly appreciated

 

 

local widget= require("widget")

local function handleButtonEvent(event)
  local phase = event.phase
  if "ended"==phase then
    print ("LOGIN PAGE")
  else
    print("NEXT PAGE")
  end
end


local signinbutton = widget.newButton
{
  left= 150,
  down= 200,
  width= 350,
  height= 150,
  defaultFile="default.png",
  overFile="over.png",
  label = "SIGNIN",
  onEvent = handleButtonEvent,
}
local signupbutton=widget.newButton
{
  right=150,
  down=200,
  width=300,
  height=150,
  defaultFile="default.png",
  overFile="over.png",
  label="SIGNUP",
  onEvent=handleButtonEvent,
  }
 



[TOPIC: post.html]
#2

ponywolf

[GLOBAL: userInfoPane.html]
ponywolf
  • Contributor

  • 268 posts
  • Corona SDK

Zerobrane shouldn't matter here. Maybe you need to pick Corona as your environment if you are looking to run it with execute button.




[topic_controls]
[/topic_controls]