diff --git a/examples/widgetapp/application.e b/examples/widgetapp/application.e
index 14677cd6..86eab8c4 100644
--- a/examples/widgetapp/application.e
+++ b/examples/widgetapp/application.e
@@ -1,13 +1,12 @@
note
- description: "simple application root class"
- date: "$Date$"
- revision: "$Revision$"
+ description : "simple application root class"
+ date : "$Date$"
+ revision : "$Revision$"
class
APPLICATION
inherit
-
WSF_DEFAULT_SERVICE
redefine
initialize
@@ -27,11 +26,13 @@ feature {NONE} -- Initialization
feature -- Basic operations
execute (req: WSF_REQUEST; res: WSF_RESPONSE)
+ local
+ page: SAMPLE_PAGE
do
- -- To send a response we need to setup, the status code and
- -- the response headers.
- res.put_header ({HTTP_STATUS_CODE}.ok, <<["Content-Type", "text/plain"], ["Content-Length", "11"]>>)
- res.put_string ("Hello World 99 just another mod")
+ -- To send a response we need to setup, the status code and
+ -- the response headers.
+ create page.make(req, res)
+ page.execute
end
end
diff --git a/examples/widgetapp/sample_page.e b/examples/widgetapp/sample_page.e
new file mode 100644
index 00000000..dcfe8f29
--- /dev/null
+++ b/examples/widgetapp/sample_page.e
@@ -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
diff --git a/examples/widgetapp/widgetapp.ecf b/examples/widgetapp/widgetapp.ecf
index 52254872..4e603bf6 100644
--- a/examples/widgetapp/widgetapp.ecf
+++ b/examples/widgetapp/widgetapp.ecf
@@ -12,6 +12,7 @@
+