Merge branch 'widget' of github.com:ynh/EWF into widget

This commit is contained in:
Severin Münger
2013-09-15 22:14:07 +02:00
6 changed files with 28 additions and 33 deletions

View File

@@ -35,9 +35,11 @@ feature {NONE} -- Initialization
map_agent_uri ("/", agent execute_hello, Void)
map_agent_uri ("/grid", agent grid_demo, Void)
map_agent_uri ("/repeater", agent repeater_demo, Void)
map_agent_uri ("/widget.js", agent load_js, Void)
map_agent_uri ("/widget.css", agent load_css, Void)
map_agent_uri ("/bootstrap.min.css", agent load_bootstrap, Void)
map_agent_uri ("/widget.js", agent load_file("widget.js", ?, ?), Void)
map_agent_uri ("/jquery.min.js", agent load_file("jquery.min.js", ?, ?), Void)
map_agent_uri ("/typeahead.min.js", agent load_file("typeahead.min.js", ?, ?), Void)
map_agent_uri ("/widget.css", agent load_file("widget.css", ?, ?), Void)
map_agent_uri ("/bootstrap.min.css", agent load_file("bootstrap.min.css", ?, ?), Void)
end
feature -- Helper: mapping
@@ -79,27 +81,11 @@ feature -- Execution
page.execute
end
load_js (req: WSF_REQUEST; res: WSF_RESPONSE)
load_file (name: STRING; req: WSF_REQUEST; res: WSF_RESPONSE)
local
f: WSF_FILE_RESPONSE
do
create f.make_html ("widget.js")
res.send (f)
end
load_css (req: WSF_REQUEST; res: WSF_RESPONSE)
local
f: WSF_FILE_RESPONSE
do
create f.make_html ("widget.css")
res.send (f)
end
load_bootstrap (req: WSF_REQUEST; res: WSF_RESPONSE)
local
f: WSF_FILE_RESPONSE
do
create f.make_html ("bootstrap.min.css")
create f.make_html (name)
res.send (f)
end

File diff suppressed because one or more lines are too long

5
examples/widgetapp/jquery.min.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@@ -27,7 +27,6 @@ feature
n4_container: WSF_FORM_ELEMENT_CONTROL [STRING]
n5_container: WSF_FORM_ELEMENT_CONTROL [STRING]
cats_container: WSF_FORM_ELEMENT_CONTROL [LIST [STRING]]
s: FLAG_AUTOCOMPLETION
do
Precursor
create form.make_form_control ("panel")
@@ -44,8 +43,7 @@ feature
n2_container.add_validator (create {WSF_DECIMAL_VALIDATOR}.make_decimal_validator ("Invalid Number"))
form.add_control (n2_container)
--Flag autocomplete
create s.make (<<["dz", "Algeria"], ["be", "Belgium"], ["ca", "Canada"], ["de", "Deutschland"], ["england", "England"], ["fi", "Finland"], ["gr", "Greece"], ["hu", "Hungary"]>>)
create autocompletion1.make_autocomplete ("autocompletion1", s)
create autocompletion1.make_autocomplete ("autocompletion1", create {FLAG_AUTOCOMPLETION}.make)
create n3_container.make_form_element ("Flag Autocomplete", autocompletion1)
form.add_control (n3_container)
--Contact autocomplete

7
examples/widgetapp/typeahead.min.js vendored Normal file

File diff suppressed because one or more lines are too long