Created first working sample page application.
This commit is contained in:
41
examples/widgetapp/sample_page.e
Normal file
41
examples/widgetapp/sample_page.e
Normal file
@@ -0,0 +1,41 @@
|
||||
note
|
||||
description: "Summary description for {SAMPLE_PAGE}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
SAMPLE_PAGE
|
||||
|
||||
inherit
|
||||
|
||||
WSF_PAGE_CONTROL
|
||||
redefine
|
||||
initialize_controls,
|
||||
process
|
||||
end
|
||||
|
||||
create
|
||||
make
|
||||
|
||||
feature
|
||||
|
||||
initialize_controls
|
||||
do
|
||||
button := create {WSF_BUTTON_CONTROL}.make ("sample_button", "I'm a button")
|
||||
control := button
|
||||
end
|
||||
|
||||
handle_click(context: WSF_PAGE_CONTROL)
|
||||
do
|
||||
if attached {SAMPLE_PAGE} context as sp then
|
||||
sp.button.set_text("Hello World! (Ueeee)")
|
||||
end
|
||||
end
|
||||
|
||||
process
|
||||
do
|
||||
end
|
||||
|
||||
button: WSF_BUTTON_CONTROL
|
||||
end
|
||||
Reference in New Issue
Block a user