Extracted the WIDGET and FORM classes out of "cms" component
and build the wsf_html library which also include the previous css lib.
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
<setting name="concurrency" value="thread"/>
|
||||
<library name="base" location="$ISE_LIBRARY\library\base\base-safe.ecf"/>
|
||||
<library name="encoder" location="..\..\..\library\text\encoder\encoder-safe.ecf" readonly="false"/>
|
||||
<library name="css" location="..\..\library\text\css\css-safe.ecf" readonly="false"/>
|
||||
<library name="wsf_html" location="..\..\..\library\server\wsf_html\wsf_html-safe.ecf" readonly="false"/>
|
||||
<library name="http" location="..\..\..\library\network\protocol\http\http-safe.ecf" readonly="false"/>
|
||||
<library name="openid" location="..\..\..\library\security\openid\consumer\openid-safe.ecf" readonly="false"/>
|
||||
<library name="process" location="$ISE_LIBRARY\library\process\process-safe.ecf"/>
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
<library name="base" location="$ISE_LIBRARY\library\base\base.ecf"/>
|
||||
<library name="encoder" location="..\..\..\library\text\encoder\encoder.ecf" readonly="false"/>
|
||||
<library name="css" location="..\..\library\text\css\css.ecf" readonly="false"/>
|
||||
<library name="wsf_html" location="..\..\..\library\server\wsf_html\wsf_html.ecf" readonly="false"/>
|
||||
<library name="http" location="..\..\..\library\network\protocol\http\http.ecf" readonly="false"/>
|
||||
<library name="openid" location="..\..\..\library\security\openid\consumer\openid.ecf" />
|
||||
<library name="process" location="$ISE_LIBRARY\library\process\process.ecf"/>
|
||||
|
||||
@@ -35,9 +35,9 @@ feature -- Execution
|
||||
set_main_content (s)
|
||||
end
|
||||
|
||||
new_table: CMS_WIDGET_AGENT_TABLE [READABLE_STRING_8]
|
||||
new_table: WSF_WIDGET_AGENT_TABLE [READABLE_STRING_8]
|
||||
local
|
||||
l_table: CMS_WIDGET_AGENT_TABLE [READABLE_STRING_8]
|
||||
l_table: WSF_WIDGET_AGENT_TABLE [READABLE_STRING_8]
|
||||
do
|
||||
create l_table.make
|
||||
l_table.add_css_style ("width: 85%%; border: solid 1px #999; padding: 2px;")
|
||||
@@ -53,10 +53,10 @@ feature -- Execution
|
||||
|
||||
l_table.set_data (<<"foo", "bar", "foobar">>)
|
||||
l_table.set_foot_data (<<"abc", "def">>)
|
||||
l_table.set_compute_item_function (agent (d: READABLE_STRING_8): CMS_WIDGET_TABLE_ROW
|
||||
l_table.set_compute_item_function (agent (d: READABLE_STRING_8): WSF_WIDGET_TABLE_ROW
|
||||
local
|
||||
i: INTEGER
|
||||
w: CMS_WIDGET_TABLE_ITEM
|
||||
w: WSF_WIDGET_TABLE_ITEM
|
||||
do
|
||||
create Result.make (d.count)
|
||||
if d.is_case_insensitive_equal ("bar") then
|
||||
|
||||
@@ -264,7 +264,7 @@ feature -- Message
|
||||
add_message (a_msg, "success")
|
||||
end
|
||||
|
||||
report_form_errors (fd: CMS_FORM_DATA)
|
||||
report_form_errors (fd: WSF_FORM_DATA)
|
||||
require
|
||||
has_error: not fd.is_valid
|
||||
do
|
||||
|
||||
@@ -203,7 +203,7 @@ feature -- Hook: form_alter
|
||||
|
||||
form_alter_hooks: detachable ARRAYED_LIST [CMS_HOOK_FORM_ALTER]
|
||||
|
||||
call_form_alter_hooks (f: CMS_FORM; a_form_data: detachable CMS_FORM_DATA; a_execution: CMS_EXECUTION)
|
||||
call_form_alter_hooks (f: CMS_FORM; a_form_data: detachable WSF_FORM_DATA; a_execution: CMS_EXECUTION)
|
||||
do
|
||||
if attached form_alter_hooks as lst then
|
||||
across
|
||||
|
||||
43
draft/application/cms/src/form/cms_form.e
Normal file
43
draft/application/cms/src/form/cms_form.e
Normal file
@@ -0,0 +1,43 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM
|
||||
|
||||
inherit
|
||||
WSF_FORM
|
||||
rename
|
||||
process as process_form
|
||||
end
|
||||
|
||||
create
|
||||
make
|
||||
|
||||
feature -- Basic operation
|
||||
|
||||
prepare (a_execution: CMS_EXECUTION)
|
||||
do
|
||||
a_execution.service.call_form_alter_hooks (Current, Void, a_execution)
|
||||
end
|
||||
|
||||
process (a_execution: CMS_EXECUTION)
|
||||
do
|
||||
process_form (a_execution.request, agent on_prepared (a_execution, ?), agent on_processed (a_execution, ?))
|
||||
end
|
||||
|
||||
on_prepared (a_execution: CMS_EXECUTION; fd: WSF_FORM_DATA)
|
||||
do
|
||||
a_execution.service.call_form_alter_hooks (Current, fd, a_execution)
|
||||
end
|
||||
|
||||
on_processed (a_execution: CMS_EXECUTION; fd: WSF_FORM_DATA)
|
||||
do
|
||||
if not fd.is_valid or fd.has_error then
|
||||
a_execution.report_form_errors (fd)
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
@@ -12,7 +12,7 @@ inherit
|
||||
|
||||
feature -- Hook
|
||||
|
||||
form_alter (a_form: CMS_FORM; a_form_data: detachable CMS_FORM_DATA; a_execution: CMS_EXECUTION)
|
||||
form_alter (a_form: CMS_FORM; a_form_data: detachable WSF_FORM_DATA; a_execution: CMS_EXECUTION)
|
||||
deferred
|
||||
end
|
||||
|
||||
|
||||
@@ -34,14 +34,14 @@ feature -- Factory
|
||||
deferred
|
||||
end
|
||||
|
||||
change_node (a_execution: CMS_EXECUTION; a_form_data: CMS_FORM_DATA; a_node: like new_node)
|
||||
change_node (a_execution: CMS_EXECUTION; a_form_data: WSF_FORM_DATA; a_node: like new_node)
|
||||
-- Apply data from `a_form_data' to a_node
|
||||
require
|
||||
a_node.has_id
|
||||
deferred
|
||||
end
|
||||
|
||||
new_node (a_execution: CMS_EXECUTION; a_form_data: CMS_FORM_DATA; a_node: detachable like new_node): CMS_NODE
|
||||
new_node (a_execution: CMS_EXECUTION; a_form_data: WSF_FORM_DATA; a_node: detachable like new_node): CMS_NODE
|
||||
-- New content created with `a_form_data'
|
||||
deferred
|
||||
ensure
|
||||
|
||||
@@ -1,17 +0,0 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_ITEM}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
deferred class
|
||||
CMS_FORM_ITEM
|
||||
|
||||
inherit
|
||||
CMS_WIDGET
|
||||
|
||||
WITH_CSS_CLASS
|
||||
|
||||
WITH_CSS_STYLE
|
||||
|
||||
end
|
||||
@@ -81,7 +81,7 @@ feature -- Execution
|
||||
|
||||
feature -- Forms
|
||||
|
||||
edit_form_submit (fd: CMS_FORM_DATA; a_roles: LIST [CMS_USER_ROLE])
|
||||
edit_form_submit (fd: WSF_FORM_DATA; a_roles: LIST [CMS_USER_ROLE])
|
||||
local
|
||||
l_role: CMS_USER_ROLE
|
||||
do
|
||||
@@ -120,9 +120,9 @@ feature -- Forms
|
||||
new_edit_form (a_action: READABLE_STRING_8; a_roles: LIST [CMS_USER_ROLE]; a_use_data: BOOLEAN): CMS_FORM
|
||||
local
|
||||
perms: ARRAYED_SET [READABLE_STRING_8]
|
||||
tb: CMS_WIDGET_AGENT_TABLE [READABLE_STRING_8]
|
||||
tb: WSF_WIDGET_AGENT_TABLE [READABLE_STRING_8]
|
||||
i: INTEGER
|
||||
tf: CMS_FORM_TEXT_INPUT
|
||||
tf: WSF_FORM_TEXT_INPUT
|
||||
do
|
||||
create perms.make (10)
|
||||
perms.compare_objects
|
||||
@@ -158,10 +158,10 @@ feature -- Forms
|
||||
|
||||
tb.add_css_style ("border: solid 1px #999;")
|
||||
tb.set_data (perms)
|
||||
tb.set_compute_item_function (agent (p: READABLE_STRING_8; ia_roles: LIST [CMS_USER_ROLE]; ia_use_data: BOOLEAN): CMS_WIDGET_TABLE_ROW
|
||||
tb.set_compute_item_function (agent (p: READABLE_STRING_8; ia_roles: LIST [CMS_USER_ROLE]; ia_use_data: BOOLEAN): WSF_WIDGET_TABLE_ROW
|
||||
local
|
||||
it: CMS_WIDGET_TABLE_ITEM
|
||||
cb: CMS_FORM_CHECKBOX_INPUT
|
||||
it: WSF_WIDGET_TABLE_ITEM
|
||||
cb: WSF_FORM_CHECKBOX_INPUT
|
||||
do
|
||||
create Result.make (1 + ia_roles.count)
|
||||
create it.make_with_text (p)
|
||||
@@ -188,21 +188,21 @@ feature -- Forms
|
||||
create Result.make (a_action, "edit-user-roles")
|
||||
Result.set_method_post
|
||||
Result.extend (tb.to_computed_table)
|
||||
Result.extend (create {CMS_FORM_SUBMIT_INPUT}.make_with_text ("op", "Apply"))
|
||||
Result.extend (create {WSF_FORM_SUBMIT_INPUT}.make_with_text ("op", "Apply"))
|
||||
|
||||
create tf.make ("new-role")
|
||||
tf.add_css_class ("horizontal")
|
||||
tf.set_size (24)
|
||||
tf.set_label ("New user role")
|
||||
Result.extend (tf)
|
||||
Result.extend (create {CMS_FORM_SUBMIT_INPUT}.make_with_text ("op", "Add role"))
|
||||
Result.extend (create {WSF_FORM_SUBMIT_INPUT}.make_with_text ("op", "Add role"))
|
||||
|
||||
create tf.make ("new-permission")
|
||||
tf.add_css_class ("horizontal")
|
||||
tf.set_size (24)
|
||||
tf.set_label ("New permission")
|
||||
Result.extend (tf)
|
||||
Result.extend (create {CMS_FORM_SUBMIT_INPUT}.make_with_text ("op", "Add permission"))
|
||||
Result.extend (create {WSF_FORM_SUBMIT_INPUT}.make_with_text ("op", "Add permission"))
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -41,11 +41,11 @@ feature -- Factory
|
||||
|
||||
fill_edit_form (f: CMS_FORM; a_node: detachable CMS_NODE)
|
||||
local
|
||||
ti: CMS_FORM_TEXT_INPUT
|
||||
fset: CMS_FORM_FIELD_SET
|
||||
ta: CMS_FORM_TEXTAREA
|
||||
tselect: CMS_FORM_SELECT
|
||||
opt: CMS_FORM_SELECT_OPTION
|
||||
ti: WSF_FORM_TEXT_INPUT
|
||||
fset: WSF_FORM_FIELD_SET
|
||||
ta: WSF_FORM_TEXTAREA
|
||||
tselect: WSF_FORM_SELECT
|
||||
opt: WSF_FORM_SELECT_OPTION
|
||||
do
|
||||
create ti.make ("title")
|
||||
ti.set_label ("Title")
|
||||
@@ -96,7 +96,7 @@ feature -- Factory
|
||||
|
||||
end
|
||||
|
||||
change_node (a_execution: CMS_EXECUTION; fd: CMS_FORM_DATA; a_node: like new_node)
|
||||
change_node (a_execution: CMS_EXECUTION; fd: WSF_FORM_DATA; a_node: like new_node)
|
||||
local
|
||||
b: detachable READABLE_STRING_8
|
||||
f: detachable CMS_FORMAT
|
||||
@@ -123,7 +123,7 @@ feature -- Factory
|
||||
end
|
||||
end
|
||||
|
||||
new_node (a_execution: CMS_EXECUTION; fd: CMS_FORM_DATA; a_node: detachable like new_node): CMS_PAGE
|
||||
new_node (a_execution: CMS_EXECUTION; fd: WSF_FORM_DATA; a_node: detachable like new_node): CMS_PAGE
|
||||
-- <Precursor>
|
||||
local
|
||||
b: detachable READABLE_STRING_8
|
||||
|
||||
@@ -18,7 +18,7 @@ feature -- Execution
|
||||
local
|
||||
b: STRING_8
|
||||
f: like edit_form
|
||||
fd: detachable CMS_FORM_DATA
|
||||
fd: detachable WSF_FORM_DATA
|
||||
do
|
||||
create b.make_empty
|
||||
if attached non_empty_string_path_parameter ("type") as s_type then
|
||||
|
||||
@@ -12,7 +12,7 @@ inherit
|
||||
|
||||
feature -- Form
|
||||
|
||||
edit_form_validate (fd: CMS_FORM_DATA; b: STRING)
|
||||
edit_form_validate (fd: WSF_FORM_DATA; b: STRING)
|
||||
local
|
||||
l_preview: BOOLEAN
|
||||
l_format: detachable CMS_FORMAT
|
||||
@@ -39,7 +39,7 @@ feature -- Form
|
||||
end
|
||||
end
|
||||
|
||||
edit_form_submit (fd: CMS_FORM_DATA; a_node: detachable CMS_NODE; a_type: CMS_CONTENT_TYPE; b: STRING)
|
||||
edit_form_submit (fd: WSF_FORM_DATA; a_node: detachable CMS_NODE; a_type: CMS_CONTENT_TYPE; b: STRING)
|
||||
local
|
||||
l_preview: BOOLEAN
|
||||
l_node: detachable CMS_NODE
|
||||
@@ -77,7 +77,7 @@ feature -- Form
|
||||
end
|
||||
end
|
||||
|
||||
-- edit_form_submit (fd: CMS_FORM_DATA; a_type: CMS_CONTENT_TYPE; b: STRING)
|
||||
-- edit_form_submit (fd: WSF_FORM_DATA; a_type: CMS_CONTENT_TYPE; b: STRING)
|
||||
-- local
|
||||
-- l_preview: BOOLEAN
|
||||
-- do
|
||||
@@ -110,8 +110,8 @@ feature -- Form
|
||||
edit_form (a_node: detachable CMS_NODE; a_url: READABLE_STRING_8; a_name: STRING; a_type: CMS_CONTENT_TYPE): CMS_FORM
|
||||
local
|
||||
f: CMS_FORM
|
||||
ts: CMS_FORM_SUBMIT_INPUT
|
||||
th: CMS_FORM_HIDDEN_INPUT
|
||||
ts: WSF_FORM_SUBMIT_INPUT
|
||||
th: WSF_FORM_HIDDEN_INPUT
|
||||
do
|
||||
create f.make (a_url, a_name)
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ feature -- Execution
|
||||
local
|
||||
b: STRING_8
|
||||
f: like edit_form
|
||||
fd: detachable CMS_FORM_DATA
|
||||
fd: detachable WSF_FORM_DATA
|
||||
do
|
||||
create b.make_empty
|
||||
if
|
||||
|
||||
@@ -18,8 +18,8 @@ feature -- Execution
|
||||
local
|
||||
b: STRING
|
||||
f: CMS_FORM
|
||||
tf: CMS_FORM_TEXT_INPUT
|
||||
ts: CMS_FORM_SUBMIT_INPUT
|
||||
tf: WSF_FORM_TEXT_INPUT
|
||||
ts: WSF_FORM_SUBMIT_INPUT
|
||||
o: OPENID_CONSUMER
|
||||
v: OPENID_CONSUMER_VALIDATION
|
||||
tb: HASH_TABLE [READABLE_STRING_8, STRING_8]
|
||||
|
||||
@@ -60,10 +60,10 @@ feature -- Hooks
|
||||
end
|
||||
end
|
||||
|
||||
form_alter (a_form: CMS_FORM; a_form_data: detachable CMS_FORM_DATA; a_execution: CMS_EXECUTION)
|
||||
form_alter (a_form: CMS_FORM; a_form_data: detachable WSF_FORM_DATA; a_execution: CMS_EXECUTION)
|
||||
local
|
||||
i: CMS_FORM_DIV
|
||||
fh: CMS_FORM_HIDDEN_INPUT
|
||||
i: WSF_FORM_DIV
|
||||
fh: WSF_FORM_HIDDEN_INPUT
|
||||
do
|
||||
if a_form.id.same_string ("openid-login") then
|
||||
create i.make_with_text_and_css_id (
|
||||
@@ -82,7 +82,7 @@ feature -- Hooks
|
||||
,
|
||||
"openid"
|
||||
)
|
||||
if attached a_form.items_by_type ({CMS_WIDGET_TEXT}) as lst and then not lst.is_empty then
|
||||
if attached a_form.items_by_type ({WSF_WIDGET_TEXT}) as lst and then not lst.is_empty then
|
||||
a_form.insert_before (i, lst.last)
|
||||
else
|
||||
a_form.extend (i)
|
||||
@@ -98,7 +98,7 @@ feature -- Hooks
|
||||
across
|
||||
f_lst as c
|
||||
loop
|
||||
if attached {CMS_FORM_TEXT_INPUT} c.item as txt then
|
||||
if attached {WSF_FORM_TEXT_INPUT} c.item as txt then
|
||||
txt.set_text_value (l_openid_nickname.to_string_32)
|
||||
end
|
||||
end
|
||||
@@ -110,7 +110,7 @@ feature -- Hooks
|
||||
across
|
||||
f_lst as c
|
||||
loop
|
||||
if attached {CMS_FORM_TEXT_INPUT} c.item as txt then
|
||||
if attached {WSF_FORM_TEXT_INPUT} c.item as txt then
|
||||
txt.set_text_value (l_openid_email.to_string_32)
|
||||
end
|
||||
end
|
||||
@@ -122,7 +122,7 @@ feature -- Hooks
|
||||
end
|
||||
end
|
||||
|
||||
openid_user_register_submitted (a_form_data: CMS_FORM_DATA)
|
||||
openid_user_register_submitted (a_form_data: WSF_FORM_DATA)
|
||||
do
|
||||
|
||||
end
|
||||
|
||||
@@ -94,7 +94,7 @@ feature -- Execution
|
||||
l_url: detachable READABLE_STRING_8
|
||||
b: STRING_8
|
||||
f: CMS_FORM
|
||||
fd: detachable CMS_FORM_DATA
|
||||
fd: detachable WSF_FORM_DATA
|
||||
do
|
||||
if
|
||||
attached {WSF_STRING} request.item ("destination") as s_dest
|
||||
@@ -134,7 +134,7 @@ feature -- Execution
|
||||
end
|
||||
end
|
||||
|
||||
on_form_submitted (fd: CMS_FORM_DATA)
|
||||
on_form_submitted (fd: WSF_FORM_DATA)
|
||||
local
|
||||
u: detachable CMS_USER
|
||||
do
|
||||
@@ -159,12 +159,12 @@ feature -- Execution
|
||||
|
||||
login_form (a_action: READABLE_STRING_8; a_form_name: READABLE_STRING_8; a_destination: READABLE_STRING_8): CMS_FORM
|
||||
local
|
||||
th: CMS_FORM_HIDDEN_INPUT
|
||||
ti: CMS_FORM_TEXT_INPUT
|
||||
tp: CMS_FORM_PASSWORD_INPUT
|
||||
ts: CMS_FORM_SUBMIT_INPUT
|
||||
l_logo: CMS_FORM_RAW_TEXT
|
||||
d: CMS_FORM_DIV
|
||||
th: WSF_FORM_HIDDEN_INPUT
|
||||
ti: WSF_FORM_TEXT_INPUT
|
||||
tp: WSF_FORM_PASSWORD_INPUT
|
||||
ts: WSF_FORM_SUBMIT_INPUT
|
||||
l_logo: WSF_FORM_RAW_TEXT
|
||||
d: WSF_FORM_DIV
|
||||
do
|
||||
create Result.make (a_action, a_form_name)
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ feature -- Execution
|
||||
local
|
||||
b: STRING_8
|
||||
f: CMS_FORM
|
||||
fd: detachable CMS_FORM_DATA
|
||||
fd: detachable WSF_FORM_DATA
|
||||
u: detachable CMS_USER
|
||||
l_is_editing_current_user: BOOLEAN
|
||||
do
|
||||
@@ -63,7 +63,7 @@ feature -- Execution
|
||||
set_main_content (b)
|
||||
end
|
||||
|
||||
edit_form_validate (fd: CMS_FORM_DATA; u: CMS_USER)
|
||||
edit_form_validate (fd: WSF_FORM_DATA; u: CMS_USER)
|
||||
local
|
||||
fu: detachable CMS_USER
|
||||
do
|
||||
@@ -81,7 +81,7 @@ feature -- Execution
|
||||
end
|
||||
end
|
||||
|
||||
edit_form_submit (fd: CMS_FORM_DATA; u: CMS_USER; a_is_editing_current_user: BOOLEAN; b: STRING)
|
||||
edit_form_submit (fd: WSF_FORM_DATA; u: CMS_USER; a_is_editing_current_user: BOOLEAN; b: STRING)
|
||||
local
|
||||
up: detachable CMS_USER_PROFILE
|
||||
l_roles: like {CMS_USER}.roles
|
||||
@@ -138,12 +138,12 @@ feature -- Execution
|
||||
edit_form (u: CMS_USER; a_url: READABLE_STRING_8; a_name: STRING): CMS_FORM
|
||||
local
|
||||
f: CMS_FORM
|
||||
ti: CMS_FORM_TEXT_INPUT
|
||||
tp: CMS_FORM_PASSWORD_INPUT
|
||||
ta: CMS_FORM_TEXTAREA
|
||||
ts: CMS_FORM_SUBMIT_INPUT
|
||||
tset: CMS_FORM_FIELD_SET
|
||||
cb: CMS_FORM_CHECKBOX_INPUT
|
||||
ti: WSF_FORM_TEXT_INPUT
|
||||
tp: WSF_FORM_PASSWORD_INPUT
|
||||
ta: WSF_FORM_TEXTAREA
|
||||
ts: WSF_FORM_SUBMIT_INPUT
|
||||
tset: WSF_FORM_FIELD_SET
|
||||
cb: WSF_FORM_CHECKBOX_INPUT
|
||||
do
|
||||
create f.make (a_url, a_name)
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ feature -- Execution
|
||||
b: STRING_8
|
||||
f: CMS_FORM
|
||||
u: detachable CMS_USER
|
||||
fd: detachable CMS_FORM_DATA
|
||||
fd: detachable WSF_FORM_DATA
|
||||
do
|
||||
set_title ("Request new password")
|
||||
create b.make_empty
|
||||
@@ -56,7 +56,7 @@ feature -- Execution
|
||||
set_main_content (b)
|
||||
end
|
||||
|
||||
password_form_validate (fd: CMS_FORM_DATA)
|
||||
password_form_validate (fd: WSF_FORM_DATA)
|
||||
local
|
||||
u: detachable CMS_USER
|
||||
do
|
||||
@@ -73,7 +73,7 @@ feature -- Execution
|
||||
initialize_primary_tabs (u)
|
||||
end
|
||||
|
||||
password_form_submit (fd: CMS_FORM_DATA; b: STRING)
|
||||
password_form_submit (fd: WSF_FORM_DATA; b: STRING)
|
||||
local
|
||||
e: detachable CMS_EMAIL
|
||||
l_uuid: UUID
|
||||
@@ -113,9 +113,9 @@ feature -- Execution
|
||||
local
|
||||
u: like user
|
||||
f: CMS_FORM
|
||||
ti: CMS_FORM_TEXT_INPUT
|
||||
th: CMS_FORM_HIDDEN_INPUT
|
||||
ts: CMS_FORM_SUBMIT_INPUT
|
||||
ti: WSF_FORM_TEXT_INPUT
|
||||
th: WSF_FORM_HIDDEN_INPUT
|
||||
ts: WSF_FORM_SUBMIT_INPUT
|
||||
err: BOOLEAN
|
||||
do
|
||||
create f.make (a_url, a_name)
|
||||
|
||||
@@ -20,7 +20,7 @@ feature -- Execution
|
||||
local
|
||||
b: STRING_8
|
||||
f: CMS_FORM
|
||||
fd: detachable CMS_FORM_DATA
|
||||
fd: detachable WSF_FORM_DATA
|
||||
do
|
||||
set_title ("Create new account")
|
||||
create b.make_empty
|
||||
@@ -50,7 +50,7 @@ feature -- Execution
|
||||
set_main_content (b)
|
||||
end
|
||||
|
||||
registration_form_validate (fd: CMS_FORM_DATA)
|
||||
registration_form_validate (fd: WSF_FORM_DATA)
|
||||
local
|
||||
u: detachable CMS_USER
|
||||
do
|
||||
@@ -68,7 +68,7 @@ feature -- Execution
|
||||
end
|
||||
end
|
||||
|
||||
registration_form_submitted (fd: CMS_FORM_DATA; buf: STRING)
|
||||
registration_form_submitted (fd: WSF_FORM_DATA; buf: STRING)
|
||||
local
|
||||
b: STRING
|
||||
u: detachable CMS_USER
|
||||
@@ -124,17 +124,17 @@ feature -- Execution
|
||||
registration_form (a_url: READABLE_STRING_8; a_name: STRING): CMS_FORM
|
||||
local
|
||||
f: CMS_FORM
|
||||
ti: CMS_FORM_TEXT_INPUT
|
||||
tp: CMS_FORM_PASSWORD_INPUT
|
||||
ta: CMS_FORM_TEXTAREA
|
||||
ts: CMS_FORM_SUBMIT_INPUT
|
||||
ti: WSF_FORM_TEXT_INPUT
|
||||
tp: WSF_FORM_PASSWORD_INPUT
|
||||
ta: WSF_FORM_TEXTAREA
|
||||
ts: WSF_FORM_SUBMIT_INPUT
|
||||
do
|
||||
create f.make (a_url, a_name)
|
||||
|
||||
create ti.make ("username")
|
||||
ti.set_label ("Username")
|
||||
ti.set_is_required (True)
|
||||
ti.set_validation_action (agent (fd: CMS_FORM_DATA)
|
||||
ti.set_validation_action (agent (fd: WSF_FORM_DATA)
|
||||
do
|
||||
if attached {WSF_STRING} fd.item ("username") as f_username and then f_username.value.count >= 5 then
|
||||
else
|
||||
|
||||
@@ -8,6 +8,12 @@ deferred class
|
||||
CMS_THEME
|
||||
|
||||
inherit
|
||||
WSF_THEME
|
||||
undefine
|
||||
url_encoded,
|
||||
html_encoded
|
||||
end
|
||||
|
||||
CMS_COMMON_API
|
||||
|
||||
feature {NONE} -- Access
|
||||
|
||||
@@ -1,14 +1,16 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM}."
|
||||
description: "Summary description for {WSF_FORM}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM
|
||||
WSF_FORM
|
||||
|
||||
inherit
|
||||
CMS_FORM_COMPOSITE
|
||||
WSF_FORM_COMPOSITE
|
||||
|
||||
WSF_WITH_HTML_ATTRIBUTE
|
||||
|
||||
create
|
||||
make
|
||||
@@ -48,41 +50,42 @@ feature -- Access
|
||||
-- Form's method
|
||||
--| GET or POST
|
||||
|
||||
encoding_type: detachable READABLE_STRING_8
|
||||
-- Encoding type
|
||||
|
||||
feature -- Basic operation
|
||||
|
||||
prepare (a_execution: CMS_EXECUTION)
|
||||
do
|
||||
a_execution.service.call_form_alter_hooks (Current, Void, a_execution)
|
||||
end
|
||||
|
||||
process (a_execution: CMS_EXECUTION)
|
||||
process (req: WSF_REQUEST; a_before_callback, a_after_callback: detachable PROCEDURE [ANY, TUPLE [WSF_FORM_DATA]])
|
||||
-- Process Current form with request `req'
|
||||
-- agent `a_before_callback' is called before the validation
|
||||
-- agent `a_after_callback' is called after the validation
|
||||
local
|
||||
fd: CMS_FORM_DATA
|
||||
fd: WSF_FORM_DATA
|
||||
do
|
||||
create fd.make (a_execution.request, Current)
|
||||
create fd.make (req, Current)
|
||||
last_data := fd
|
||||
a_execution.service.call_form_alter_hooks (Current, fd, a_execution)
|
||||
if a_before_callback /= Void then
|
||||
a_before_callback.call ([fd])
|
||||
end
|
||||
fd.validate
|
||||
fd.apply_to_associated_form -- Maybe only when has error?
|
||||
if fd.is_valid then
|
||||
fd.submit
|
||||
if fd.has_error then
|
||||
a_execution.report_form_errors (fd)
|
||||
end
|
||||
else
|
||||
a_execution.report_form_errors (fd)
|
||||
end
|
||||
if a_after_callback /= Void then
|
||||
a_after_callback.call ([fd])
|
||||
end
|
||||
end
|
||||
|
||||
last_data: detachable CMS_FORM_DATA
|
||||
last_data: detachable WSF_FORM_DATA
|
||||
|
||||
feature -- Validation
|
||||
|
||||
validation_actions: ACTION_SEQUENCE [TUPLE [CMS_FORM_DATA]]
|
||||
validation_actions: ACTION_SEQUENCE [TUPLE [WSF_FORM_DATA]]
|
||||
-- Procedure to validate the data
|
||||
-- report error if not valid
|
||||
|
||||
submit_actions: ACTION_SEQUENCE [TUPLE [CMS_FORM_DATA]]
|
||||
submit_actions: ACTION_SEQUENCE [TUPLE [WSF_FORM_DATA]]
|
||||
-- Submit actions
|
||||
|
||||
feature -- Element change
|
||||
@@ -97,17 +100,30 @@ feature -- Element change
|
||||
method := "POST"
|
||||
end
|
||||
|
||||
set_encoding_type (s: like encoding_type)
|
||||
do
|
||||
encoding_type := s
|
||||
end
|
||||
|
||||
set_multipart_form_data_encoding_type
|
||||
do
|
||||
encoding_type := "multipart/form-data"
|
||||
end
|
||||
|
||||
feature -- Optional
|
||||
|
||||
html_classes: ARRAYED_LIST [STRING_8]
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
local
|
||||
s: STRING_8
|
||||
do
|
||||
a_html.append ("<form action=%""+ action +"%" id=%""+ id +"%" method=%""+ method +"%" ")
|
||||
a_html.append ("<form action=%""+ action +"%" id=%""+ id +"%" method=%""+ method +"%"")
|
||||
if attached encoding_type as enctype then
|
||||
a_html.append (" enctype=%""+ enctype +"%"")
|
||||
end
|
||||
if not html_classes.is_empty then
|
||||
create s.make_empty
|
||||
across
|
||||
@@ -129,7 +145,7 @@ feature -- Conversion
|
||||
a_html.append ("</form>%N")
|
||||
end
|
||||
|
||||
to_html (a_theme: CMS_THEME): STRING_8
|
||||
to_html (a_theme: WSF_THEME): STRING_8
|
||||
do
|
||||
create Result.make_empty
|
||||
append_to_html (a_theme, Result)
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_BUTTON_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_BUTTON_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_BUTTON_INPUT
|
||||
WSF_FORM_BUTTON_INPUT
|
||||
|
||||
inherit
|
||||
CMS_FORM_INPUT
|
||||
WSF_FORM_INPUT
|
||||
|
||||
create
|
||||
make
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_CHECKBOX_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_CHECKBOX_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_CHECKBOX_INPUT
|
||||
WSF_FORM_CHECKBOX_INPUT
|
||||
|
||||
inherit
|
||||
CMS_FORM_SELECTABLE_INPUT
|
||||
WSF_FORM_SELECTABLE_INPUT
|
||||
|
||||
create
|
||||
make,
|
||||
@@ -5,10 +5,10 @@ note
|
||||
revision : "$Revision$"
|
||||
|
||||
deferred class
|
||||
CMS_FORM_COMPOSITE
|
||||
WSF_FORM_COMPOSITE
|
||||
|
||||
inherit
|
||||
CMS_WIDGET_COMPOSITE
|
||||
WSF_WIDGET_COMPOSITE
|
||||
redefine
|
||||
extend
|
||||
end
|
||||
@@ -22,18 +22,18 @@ feature -- Status
|
||||
|
||||
feature -- Access
|
||||
|
||||
fields_by_name (a_name: READABLE_STRING_GENERAL): detachable LIST [CMS_FORM_FIELD]
|
||||
fields_by_name (a_name: READABLE_STRING_GENERAL): detachable LIST [WSF_FORM_FIELD]
|
||||
do
|
||||
Result := fields_by_name_from (Current, a_name)
|
||||
end
|
||||
|
||||
feature -- Change
|
||||
|
||||
extend (i: CMS_WIDGET)
|
||||
extend (i: WSF_WIDGET)
|
||||
local
|
||||
n: READABLE_STRING_8
|
||||
do
|
||||
if attached {CMS_FORM_FIELD} i as l_field then
|
||||
if attached {WSF_FORM_FIELD} i as l_field then
|
||||
n := l_field.name
|
||||
if n.is_empty then
|
||||
n := (items.count + 1).out
|
||||
@@ -45,34 +45,34 @@ feature -- Change
|
||||
|
||||
feature {NONE} -- Implementation: Items
|
||||
|
||||
container_has_field (a_container: ITERABLE [CMS_WIDGET]; a_name: READABLE_STRING_GENERAL): BOOLEAN
|
||||
container_has_field (a_container: ITERABLE [WSF_WIDGET]; a_name: READABLE_STRING_GENERAL): BOOLEAN
|
||||
do
|
||||
across
|
||||
a_container as i
|
||||
until
|
||||
Result
|
||||
loop
|
||||
if attached {CMS_FORM_FIELD} i.item as l_field and then l_field.name.same_string_general (a_name) then
|
||||
if attached {WSF_FORM_FIELD} i.item as l_field and then l_field.name.same_string_general (a_name) then
|
||||
Result := True
|
||||
elseif attached {ITERABLE [CMS_WIDGET]} i.item as l_cont then
|
||||
elseif attached {ITERABLE [WSF_WIDGET]} i.item as l_cont then
|
||||
Result := container_has_field (l_cont, a_name)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
fields_by_name_from (a_container: ITERABLE [CMS_WIDGET]; a_name: READABLE_STRING_GENERAL): detachable ARRAYED_LIST [CMS_FORM_FIELD]
|
||||
fields_by_name_from (a_container: ITERABLE [WSF_WIDGET]; a_name: READABLE_STRING_GENERAL): detachable ARRAYED_LIST [WSF_FORM_FIELD]
|
||||
local
|
||||
res: detachable ARRAYED_LIST [CMS_FORM_FIELD]
|
||||
res: detachable ARRAYED_LIST [WSF_FORM_FIELD]
|
||||
do
|
||||
across
|
||||
a_container as i
|
||||
loop
|
||||
if attached {CMS_FORM_FIELD} i.item as l_field and then l_field.name.same_string_general (a_name) then
|
||||
if attached {WSF_FORM_FIELD} i.item as l_field and then l_field.name.same_string_general (a_name) then
|
||||
if res = Void then
|
||||
create res.make (1)
|
||||
end
|
||||
res.force (l_field)
|
||||
elseif attached {ITERABLE [CMS_WIDGET]} i.item as l_cont then
|
||||
elseif attached {ITERABLE [WSF_WIDGET]} i.item as l_cont then
|
||||
if attached fields_by_name_from (l_cont, a_name) as lst then
|
||||
if res = Void then
|
||||
res := lst
|
||||
@@ -5,17 +5,17 @@ note
|
||||
revision : "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_DATA
|
||||
WSF_FORM_DATA
|
||||
|
||||
inherit
|
||||
TABLE_ITERABLE [detachable WSF_VALUE, READABLE_STRING_8]
|
||||
|
||||
create {CMS_FORM}
|
||||
create {WSF_FORM}
|
||||
make
|
||||
|
||||
feature {NONE} -- Initialization
|
||||
|
||||
make (req: WSF_REQUEST; a_form: CMS_FORM)
|
||||
make (req: WSF_REQUEST; a_form: WSF_FORM)
|
||||
-- Initialize `Current'.
|
||||
do
|
||||
form := a_form
|
||||
@@ -25,7 +25,7 @@ feature {NONE} -- Initialization
|
||||
|
||||
feature -- Access
|
||||
|
||||
form: CMS_FORM
|
||||
form: WSF_FORM
|
||||
|
||||
feature -- Status
|
||||
|
||||
@@ -132,11 +132,11 @@ feature -- Basic operation
|
||||
form.validation_actions.call ([Current])
|
||||
end
|
||||
|
||||
validate_item (w: CMS_WIDGET)
|
||||
validate_item (w: WSF_WIDGET)
|
||||
do
|
||||
if attached {CMS_FORM_FIELD} w as l_field then
|
||||
if attached {WSF_FORM_FIELD} w as l_field then
|
||||
l_field.validate (Current)
|
||||
elseif attached {ITERABLE [CMS_WIDGET]} w as lst then
|
||||
elseif attached {ITERABLE [WSF_WIDGET]} w as lst then
|
||||
across
|
||||
lst as c
|
||||
loop
|
||||
@@ -182,16 +182,16 @@ feature -- Basic operation
|
||||
|
||||
feature {NONE} -- Implementation: apply
|
||||
|
||||
apply_to_associated_form_item (a_name: READABLE_STRING_8; a_value: detachable WSF_VALUE; i: CMS_WIDGET)
|
||||
apply_to_associated_form_item (a_name: READABLE_STRING_8; a_value: detachable WSF_VALUE; i: WSF_WIDGET)
|
||||
local
|
||||
do
|
||||
if attached {CMS_FORM_FIELD} i as l_field then
|
||||
if not attached {CMS_FORM_SUBMIT_INPUT} l_field then
|
||||
if attached {WSF_FORM_FIELD} i as l_field then
|
||||
if not attached {WSF_FORM_SUBMIT_INPUT} l_field then
|
||||
if l_field.name.same_string (a_name) then
|
||||
l_field.set_value (a_value)
|
||||
end
|
||||
end
|
||||
elseif attached {ITERABLE [CMS_WIDGET]} i as l_set then
|
||||
elseif attached {ITERABLE [WSF_WIDGET]} i as l_set then
|
||||
across
|
||||
l_set as c
|
||||
loop
|
||||
@@ -231,20 +231,20 @@ feature {NONE} -- Implementation
|
||||
get_form_items (req, form)
|
||||
end
|
||||
|
||||
get_form_items (req: WSF_REQUEST; lst: ITERABLE [CMS_WIDGET])
|
||||
get_form_items (req: WSF_REQUEST; lst: ITERABLE [WSF_WIDGET])
|
||||
do
|
||||
across
|
||||
lst as c
|
||||
loop
|
||||
if attached {CMS_FORM_FIELD} c.item as l_field then
|
||||
if attached {WSF_FORM_FIELD} c.item as l_field then
|
||||
get_form_field_item (req, l_field, l_field.name)
|
||||
elseif attached {ITERABLE [CMS_WIDGET]} c.item as l_set then
|
||||
elseif attached {ITERABLE [WSF_WIDGET]} c.item as l_set then
|
||||
get_form_items (req, l_set)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
get_form_field_item (req: WSF_REQUEST; i: CMS_FORM_FIELD; n: READABLE_STRING_8)
|
||||
get_form_field_item (req: WSF_REQUEST; i: WSF_FORM_FIELD; n: READABLE_STRING_8)
|
||||
local
|
||||
v: detachable WSF_VALUE
|
||||
do
|
||||
@@ -269,7 +269,7 @@ feature {NONE} -- Implementation
|
||||
end
|
||||
end
|
||||
|
||||
add_error (a_field: detachable CMS_FORM_FIELD; a_msg: detachable READABLE_STRING_8)
|
||||
add_error (a_field: detachable WSF_FORM_FIELD; a_msg: detachable READABLE_STRING_8)
|
||||
local
|
||||
err: like errors
|
||||
do
|
||||
@@ -322,7 +322,7 @@ feature -- Reports
|
||||
Result := attached errors as err and then not err.is_empty
|
||||
end
|
||||
|
||||
errors: detachable ARRAYED_LIST [TUPLE [field: detachable CMS_FORM_FIELD; message: detachable READABLE_STRING_8]]
|
||||
errors: detachable ARRAYED_LIST [TUPLE [field: detachable WSF_FORM_FIELD; message: detachable READABLE_STRING_8]]
|
||||
|
||||
invariant
|
||||
|
||||
@@ -5,14 +5,14 @@ note
|
||||
revision : "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_DIV
|
||||
WSF_FORM_DIV
|
||||
|
||||
inherit
|
||||
CMS_FORM_ITEM
|
||||
WSF_FORM_ITEM
|
||||
|
||||
CMS_FORM_COMPOSITE
|
||||
WSF_FORM_COMPOSITE
|
||||
|
||||
WITH_CSS_ID
|
||||
WSF_WITH_CSS_ID
|
||||
|
||||
create
|
||||
make,
|
||||
@@ -32,16 +32,16 @@ feature {NONE} -- Initialization
|
||||
|
||||
make_with_text (s: READABLE_STRING_8)
|
||||
do
|
||||
make_with_item (create {CMS_FORM_RAW_TEXT}.make (s))
|
||||
make_with_item (create {WSF_FORM_RAW_TEXT}.make (s))
|
||||
end
|
||||
|
||||
make_with_item (i: CMS_WIDGET)
|
||||
make_with_item (i: WSF_WIDGET)
|
||||
do
|
||||
initialize_with_count (1)
|
||||
extend (i)
|
||||
end
|
||||
|
||||
make_with_items (it: ITERABLE [CMS_WIDGET])
|
||||
make_with_items (it: ITERABLE [WSF_WIDGET])
|
||||
do
|
||||
initialize_with_count (2)
|
||||
across
|
||||
@@ -51,7 +51,7 @@ feature {NONE} -- Initialization
|
||||
end
|
||||
end
|
||||
|
||||
make_with_item_and_css_id (i: CMS_WIDGET; a_css_id: READABLE_STRING_8)
|
||||
make_with_item_and_css_id (i: WSF_WIDGET; a_css_id: READABLE_STRING_8)
|
||||
do
|
||||
make_with_item (i)
|
||||
set_css_id (a_css_id)
|
||||
@@ -65,7 +65,7 @@ feature {NONE} -- Initialization
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
do
|
||||
a_html.append ("<div")
|
||||
append_css_class_to (a_html, Void)
|
||||
@@ -1,16 +1,16 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_ITEM}."
|
||||
description: "Summary description for {WSF_FORM_ITEM}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
deferred class
|
||||
CMS_FORM_FIELD
|
||||
WSF_FORM_FIELD
|
||||
|
||||
inherit
|
||||
CMS_FORM_ITEM
|
||||
WSF_FORM_ITEM
|
||||
|
||||
WITH_CSS_ID
|
||||
WSF_WITH_CSS_ID
|
||||
|
||||
DEBUG_OUTPUT
|
||||
|
||||
@@ -40,10 +40,10 @@ feature -- Status report
|
||||
|
||||
feature -- Validation
|
||||
|
||||
validation_action: detachable PROCEDURE [ANY, TUPLE [CMS_FORM_DATA]]
|
||||
validation_action: detachable PROCEDURE [ANY, TUPLE [WSF_FORM_DATA]]
|
||||
-- Function returning True if valid, otherwise False
|
||||
|
||||
validate (fd: CMS_FORM_DATA)
|
||||
validate (fd: WSF_FORM_DATA)
|
||||
do
|
||||
if attached validation_action as act then
|
||||
act.call ([fd])
|
||||
@@ -102,7 +102,7 @@ feature -- Element change
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
local
|
||||
l_class_items: detachable ARRAYED_LIST [READABLE_STRING_8]
|
||||
do
|
||||
@@ -138,7 +138,7 @@ feature -- Conversion
|
||||
a_html.append ("</div>")
|
||||
end
|
||||
|
||||
append_item_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_item_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
deferred
|
||||
end
|
||||
|
||||
@@ -5,14 +5,14 @@ note
|
||||
revision : "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_FIELD_SET
|
||||
WSF_FORM_FIELD_SET
|
||||
|
||||
inherit
|
||||
CMS_FORM_ITEM
|
||||
WSF_FORM_ITEM
|
||||
|
||||
CMS_FORM_COMPOSITE
|
||||
WSF_FORM_COMPOSITE
|
||||
|
||||
WITH_CSS_ID
|
||||
WSF_WITH_CSS_ID
|
||||
|
||||
create
|
||||
make
|
||||
@@ -59,7 +59,7 @@ feature -- Change
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
do
|
||||
a_html.append ("<fieldset")
|
||||
append_css_class_to (a_html, Void)
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_FILE_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_FILE_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_FILE_INPUT
|
||||
WSF_FORM_FILE_INPUT
|
||||
|
||||
inherit
|
||||
CMS_FORM_INPUT
|
||||
WSF_FORM_INPUT
|
||||
redefine
|
||||
specific_input_attributes_string
|
||||
end
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_HIDDEN_INPUT
|
||||
WSF_FORM_HIDDEN_INPUT
|
||||
|
||||
inherit
|
||||
CMS_FORM_INPUT
|
||||
WSF_FORM_INPUT
|
||||
redefine
|
||||
input_type,
|
||||
append_item_to_html
|
||||
@@ -27,7 +27,7 @@ feature -- Access
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_item_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_item_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
do
|
||||
a_html.append ("<div style=%"display:none%">")
|
||||
Precursor (a_theme, a_html)
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_IMAGE_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_IMAGE_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_IMAGE_INPUT
|
||||
WSF_FORM_IMAGE_INPUT
|
||||
|
||||
inherit
|
||||
CMS_FORM_INPUT
|
||||
WSF_FORM_INPUT
|
||||
redefine
|
||||
specific_input_attributes_string
|
||||
end
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
deferred class
|
||||
CMS_FORM_INPUT
|
||||
WSF_FORM_INPUT
|
||||
|
||||
inherit
|
||||
CMS_FORM_FIELD
|
||||
WSF_FORM_FIELD
|
||||
|
||||
feature {NONE} -- Initialization
|
||||
|
||||
@@ -78,7 +78,7 @@ feature -- Element change
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_item_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_item_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
local
|
||||
old_count: INTEGER
|
||||
do
|
||||
@@ -121,7 +121,7 @@ feature -- Conversion
|
||||
|
||||
feature {NONE} -- Implementation
|
||||
|
||||
append_child_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_child_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
-- Specific child element if any.
|
||||
--| To redefine if needed
|
||||
do
|
||||
17
library/server/wsf_html/form/wsf_form_item.e
Normal file
17
library/server/wsf_html/form/wsf_form_item.e
Normal file
@@ -0,0 +1,17 @@
|
||||
note
|
||||
description: "Summary description for {WSF_FORM_ITEM}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
deferred class
|
||||
WSF_FORM_ITEM
|
||||
|
||||
inherit
|
||||
WSF_WIDGET
|
||||
|
||||
WSF_WITH_CSS_CLASS
|
||||
|
||||
WSF_WITH_CSS_STYLE
|
||||
|
||||
end
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_PASSWORD_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_PASSWORD_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_PASSWORD_INPUT
|
||||
WSF_FORM_PASSWORD_INPUT
|
||||
|
||||
inherit
|
||||
CMS_FORM_INPUT
|
||||
WSF_FORM_INPUT
|
||||
redefine
|
||||
input_type
|
||||
end
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_RADIO_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_RADIO_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_RADIO_INPUT
|
||||
WSF_FORM_RADIO_INPUT
|
||||
|
||||
inherit
|
||||
CMS_FORM_SELECTABLE_INPUT
|
||||
WSF_FORM_SELECTABLE_INPUT
|
||||
|
||||
create
|
||||
make,
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_RAW_TEXT}."
|
||||
description: "Summary description for {WSF_FORM_RAW_TEXT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_RAW_TEXT
|
||||
WSF_FORM_RAW_TEXT
|
||||
|
||||
inherit
|
||||
CMS_WIDGET_TEXT
|
||||
WSF_WIDGET_TEXT
|
||||
rename
|
||||
set_text as set_value,
|
||||
make_with_text as make
|
||||
@@ -21,12 +21,12 @@ create
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
do
|
||||
append_item_html_to (a_theme, a_html)
|
||||
end
|
||||
|
||||
append_item_html_to (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_item_html_to (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
do
|
||||
a_html.append (text)
|
||||
end
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_RESET_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_RESET_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_RESET_INPUT
|
||||
WSF_FORM_RESET_INPUT
|
||||
|
||||
inherit
|
||||
CMS_FORM_INPUT
|
||||
WSF_FORM_INPUT
|
||||
|
||||
create
|
||||
make
|
||||
@@ -1,16 +1,16 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_SELECT}."
|
||||
description: "Summary description for {WSF_FORM_SELECT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_SELECT
|
||||
WSF_FORM_SELECT
|
||||
|
||||
inherit
|
||||
CMS_FORM_FIELD
|
||||
WSF_FORM_FIELD
|
||||
|
||||
CMS_FORM_UTILITY
|
||||
WSF_FORM_UTILITY
|
||||
|
||||
create
|
||||
make
|
||||
@@ -25,13 +25,13 @@ feature {NONE} -- Initialization
|
||||
|
||||
feature -- Access
|
||||
|
||||
options: ARRAYED_LIST [CMS_FORM_SELECT_OPTION]
|
||||
options: ARRAYED_LIST [WSF_FORM_SELECT_OPTION]
|
||||
|
||||
feature -- Element change
|
||||
|
||||
set_text_by_value (a_text: detachable READABLE_STRING_GENERAL)
|
||||
local
|
||||
opt: CMS_FORM_SELECT_OPTION
|
||||
opt: WSF_FORM_SELECT_OPTION
|
||||
l_found: BOOLEAN
|
||||
v: READABLE_STRING_8
|
||||
do
|
||||
@@ -96,14 +96,14 @@ feature -- Element change
|
||||
end
|
||||
end
|
||||
|
||||
add_option (opt: CMS_FORM_SELECT_OPTION)
|
||||
add_option (opt: WSF_FORM_SELECT_OPTION)
|
||||
do
|
||||
options.force (opt)
|
||||
end
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_item_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_item_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
local
|
||||
l_is_already_selected: BOOLEAN
|
||||
h: detachable STRING_8
|
||||
@@ -5,10 +5,10 @@ note
|
||||
revision : "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_SELECT_OPTION
|
||||
WSF_FORM_SELECT_OPTION
|
||||
|
||||
inherit
|
||||
CMS_FORM_SELECTABLE_ITEM
|
||||
WSF_FORM_SELECTABLE_ITEM
|
||||
|
||||
create
|
||||
make
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_SELECTABLE_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_SELECTABLE_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
deferred class
|
||||
CMS_FORM_SELECTABLE_INPUT
|
||||
WSF_FORM_SELECTABLE_INPUT
|
||||
|
||||
inherit
|
||||
CMS_FORM_INPUT
|
||||
WSF_FORM_INPUT
|
||||
rename
|
||||
default_value as value,
|
||||
make_with_text as make_with_value
|
||||
@@ -18,7 +18,7 @@ inherit
|
||||
append_child_to_html
|
||||
end
|
||||
|
||||
CMS_FORM_SELECTABLE_ITEM
|
||||
WSF_FORM_SELECTABLE_ITEM
|
||||
rename
|
||||
is_selected as checked,
|
||||
set_is_selected as set_checked
|
||||
@@ -87,7 +87,7 @@ feature -- Change
|
||||
|
||||
feature {NONE} -- Implementation
|
||||
|
||||
append_child_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_child_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
-- Specific child element if any.
|
||||
--| To redefine if needed
|
||||
do
|
||||
@@ -1,10 +1,10 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_SELECTABLE_ITEM}."
|
||||
description: "Summary description for {WSF_FORM_SELECTABLE_ITEM}."
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
deferred class
|
||||
CMS_FORM_SELECTABLE_ITEM
|
||||
WSF_FORM_SELECTABLE_ITEM
|
||||
|
||||
feature -- Status report
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_SUBMIT_INPUT
|
||||
WSF_FORM_SUBMIT_INPUT
|
||||
|
||||
inherit
|
||||
CMS_FORM_INPUT
|
||||
WSF_FORM_INPUT
|
||||
|
||||
create
|
||||
make,
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_TEXT_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_TEXT_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_TEXT_INPUT
|
||||
WSF_FORM_TEXT_INPUT
|
||||
|
||||
inherit
|
||||
CMS_FORM_INPUT
|
||||
WSF_FORM_INPUT
|
||||
|
||||
create
|
||||
make,
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_INPUT}."
|
||||
description: "Summary description for {WSF_FORM_INPUT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_TEXTAREA
|
||||
WSF_FORM_TEXTAREA
|
||||
|
||||
inherit
|
||||
CMS_FORM_FIELD
|
||||
WSF_FORM_FIELD
|
||||
|
||||
create
|
||||
make
|
||||
@@ -61,7 +61,7 @@ feature -- Element change
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_item_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_item_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
do
|
||||
a_html.append ("<textarea name=%""+ name +"%"")
|
||||
if rows > 0 then
|
||||
@@ -1,11 +1,11 @@
|
||||
note
|
||||
description: "Summary description for {CMS_FORM_UTILITY}."
|
||||
description: "Summary description for {WSF_FORM_UTILITY}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_FORM_UTILITY
|
||||
WSF_FORM_UTILITY
|
||||
|
||||
feature -- Converter
|
||||
|
||||
37
library/server/wsf_html/form/wsf_theme.e
Normal file
37
library/server/wsf_html/form/wsf_theme.e
Normal file
@@ -0,0 +1,37 @@
|
||||
note
|
||||
description: "Summary description for {WSF_THEME}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
WSF_THEME
|
||||
|
||||
feature -- Access
|
||||
|
||||
url_encoded (s: detachable READABLE_STRING_GENERAL): STRING_8
|
||||
local
|
||||
enc: URL_ENCODER
|
||||
do
|
||||
create enc
|
||||
if s /= Void then
|
||||
Result := enc.general_encoded_string (s)
|
||||
else
|
||||
create Result.make_empty
|
||||
end
|
||||
end
|
||||
|
||||
html_encoded (s: detachable READABLE_STRING_GENERAL): STRING_8
|
||||
local
|
||||
enc: HTML_ENCODER
|
||||
do
|
||||
create enc
|
||||
if s /= Void then
|
||||
Result := enc.general_encoded_string (s)
|
||||
else
|
||||
create Result.make_empty
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
end
|
||||
@@ -1,10 +1,10 @@
|
||||
note
|
||||
description: "Summary description for {WITH_CSS_CLASS}."
|
||||
description: "Summary description for {WSF_WITH_CSS_CLASS}."
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
deferred class
|
||||
WITH_CSS_CLASS
|
||||
WSF_WITH_CSS_CLASS
|
||||
|
||||
feature -- Status report
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
note
|
||||
description: "Summary description for {WITH_CSS_ID}."
|
||||
description: "Summary description for {WSF_WITH_CSS_ID}."
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
deferred class
|
||||
WITH_CSS_ID
|
||||
WSF_WITH_CSS_ID
|
||||
|
||||
feature -- Status report
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
note
|
||||
description: "Summary description for {WITH_CSS_STYLE}."
|
||||
description: "Summary description for {WSF_WITH_CSS_STYLE}."
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
deferred class
|
||||
WITH_CSS_STYLE
|
||||
WSF_WITH_CSS_STYLE
|
||||
|
||||
feature -- Status report
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
note
|
||||
description: "Summary description for {WITH_HTML_ATTRIBUTE}."
|
||||
description: "Summary description for {WSF_WITH_HTML_ATTRIBUTE}."
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
deferred class
|
||||
WITH_HTML_ATTRIBUTE
|
||||
WSF_WITH_HTML_ATTRIBUTE
|
||||
|
||||
feature -- Status report
|
||||
|
||||
@@ -1,19 +1,19 @@
|
||||
note
|
||||
description: "Summary description for {CMS_WIDGET}."
|
||||
description: "Summary description for {WSF_WIDGET}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
deferred class
|
||||
CMS_WIDGET
|
||||
WSF_WIDGET
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
deferred
|
||||
end
|
||||
|
||||
to_html (a_theme: CMS_THEME): STRING_8
|
||||
to_html (a_theme: WSF_THEME): STRING_8
|
||||
do
|
||||
create Result.make_empty
|
||||
append_to_html (a_theme, Result)
|
||||
@@ -1,26 +1,26 @@
|
||||
note
|
||||
description: "Summary description for {CMS_WIDGET_TABLE}."
|
||||
description: "Summary description for {WSF_WIDGET_TABLE}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_WIDGET_AGENT_TABLE [G]
|
||||
WSF_WIDGET_AGENT_TABLE [G]
|
||||
|
||||
inherit
|
||||
CMS_WIDGET
|
||||
WSF_WIDGET
|
||||
|
||||
WITH_CSS_ID
|
||||
WSF_WITH_CSS_ID
|
||||
|
||||
WITH_CSS_CLASS
|
||||
WSF_WITH_CSS_CLASS
|
||||
|
||||
WITH_CSS_STYLE
|
||||
WSF_WITH_CSS_STYLE
|
||||
|
||||
create
|
||||
make
|
||||
|
||||
convert
|
||||
to_computed_table: {CMS_WIDGET_TABLE}
|
||||
to_computed_table: {WSF_WIDGET_TABLE}
|
||||
|
||||
feature {NONE} -- Initialization
|
||||
|
||||
@@ -36,9 +36,9 @@ feature -- Access
|
||||
Result := columns.count
|
||||
end
|
||||
|
||||
columns: ARRAY [CMS_WIDGET_TABLE_COLUMN]
|
||||
columns: ARRAY [WSF_WIDGET_TABLE_COLUMN]
|
||||
|
||||
column (c: INTEGER): CMS_WIDGET_TABLE_COLUMN
|
||||
column (c: INTEGER): WSF_WIDGET_TABLE_COLUMN
|
||||
do
|
||||
if c > column_count then
|
||||
set_column_count (c)
|
||||
@@ -60,7 +60,7 @@ feature -- Access
|
||||
data: detachable ITERABLE [G]
|
||||
-- tbody
|
||||
|
||||
compute_item_function: detachable FUNCTION [ANY, TUPLE [data: G], CMS_WIDGET_TABLE_ROW]
|
||||
compute_item_function: detachable FUNCTION [ANY, TUPLE [data: G], WSF_WIDGET_TABLE_ROW]
|
||||
|
||||
feature -- Change
|
||||
|
||||
@@ -87,12 +87,12 @@ feature -- Change
|
||||
set_column_count (nb: INTEGER)
|
||||
do
|
||||
if nb > columns.count then
|
||||
-- columns.conservative_resize_with_default (create {CMS_WIDGET_TABLE_COLUMN}, 1, nb)
|
||||
-- columns.conservative_resize_with_default (create {WSF_WIDGET_TABLE_COLUMN}, 1, nb)
|
||||
from
|
||||
until
|
||||
columns.count = nb
|
||||
loop
|
||||
columns.force (create {CMS_WIDGET_TABLE_COLUMN}.make (columns.upper + 1), columns.upper + 1)
|
||||
columns.force (create {WSF_WIDGET_TABLE_COLUMN}.make (columns.upper + 1), columns.upper + 1)
|
||||
end
|
||||
else
|
||||
columns.remove_tail (columns.count - nb)
|
||||
@@ -111,9 +111,9 @@ feature -- Change
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
to_computed_table: CMS_WIDGET_TABLE
|
||||
to_computed_table: WSF_WIDGET_TABLE
|
||||
local
|
||||
col: CMS_WIDGET_TABLE_COLUMN
|
||||
col: WSF_WIDGET_TABLE_COLUMN
|
||||
do
|
||||
create Result.make
|
||||
Result.set_column_count (column_count)
|
||||
@@ -156,7 +156,7 @@ feature -- Conversion
|
||||
|
||||
feature -- Conversion: HTML
|
||||
|
||||
append_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
local
|
||||
l_use_tbody: BOOLEAN
|
||||
do
|
||||
@@ -200,7 +200,7 @@ feature -- Conversion: HTML
|
||||
a_html.append ("</table>")
|
||||
end
|
||||
|
||||
append_data_to_html (lst: ITERABLE [G]; a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_data_to_html (lst: ITERABLE [G]; a_theme: WSF_THEME; a_html: STRING_8)
|
||||
local
|
||||
fct: like compute_item_function
|
||||
do
|
||||
@@ -5,10 +5,10 @@ note
|
||||
revision : "$Revision$"
|
||||
|
||||
deferred class
|
||||
CMS_WIDGET_COMPOSITE
|
||||
WSF_WIDGET_COMPOSITE
|
||||
|
||||
inherit
|
||||
ITERABLE [CMS_WIDGET]
|
||||
ITERABLE [WSF_WIDGET]
|
||||
|
||||
feature {NONE} -- Initialization
|
||||
|
||||
@@ -24,7 +24,7 @@ feature -- Status
|
||||
Result := count = 0
|
||||
end
|
||||
|
||||
has_item (i: CMS_WIDGET): BOOLEAN
|
||||
has_item (i: WSF_WIDGET): BOOLEAN
|
||||
do
|
||||
if has_immediate_item (i) then
|
||||
Result := True
|
||||
@@ -32,21 +32,21 @@ feature -- Status
|
||||
across
|
||||
items as c
|
||||
loop
|
||||
if attached {CMS_WIDGET_COMPOSITE} c.item as comp then
|
||||
if attached {WSF_WIDGET_COMPOSITE} c.item as comp then
|
||||
Result := comp.has_item (i)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
has_immediate_item (i: CMS_WIDGET): BOOLEAN
|
||||
has_immediate_item (i: WSF_WIDGET): BOOLEAN
|
||||
do
|
||||
Result := items.has (i)
|
||||
end
|
||||
|
||||
feature -- Access: cursor
|
||||
|
||||
new_cursor: ITERATION_CURSOR [CMS_WIDGET]
|
||||
new_cursor: ITERATION_CURSOR [WSF_WIDGET]
|
||||
-- Fresh cursor associated with current structure
|
||||
do
|
||||
Result := items.new_cursor
|
||||
@@ -60,7 +60,7 @@ feature -- Access
|
||||
across
|
||||
items as c
|
||||
loop
|
||||
if attached {CMS_WIDGET_COMPOSITE} c.item as comp then
|
||||
if attached {WSF_WIDGET_COMPOSITE} c.item as comp then
|
||||
Result := Result + comp.count
|
||||
end
|
||||
end
|
||||
@@ -71,9 +71,9 @@ feature -- Access
|
||||
Result := items.count
|
||||
end
|
||||
|
||||
items_by_type (a_type: TYPE [detachable ANY]): detachable LIST [CMS_WIDGET]
|
||||
-- All CMS_WIDGET items conforming to a_type.
|
||||
-- Warning: you should pass {detachable CMS_FORM_SUBMIT_INPUT} rather than just {CMS_FORM_SUBMIT_INPUT}
|
||||
items_by_type (a_type: TYPE [detachable ANY]): detachable LIST [WSF_WIDGET]
|
||||
-- All WSF_WIDGET items conforming to a_type.
|
||||
-- Warning: you should pass {detachable WSF_FORM_SUBMIT_INPUT} rather than just {WSF_FORM_SUBMIT_INPUT}
|
||||
local
|
||||
int: INTERNAL
|
||||
tid: INTEGER
|
||||
@@ -93,12 +93,12 @@ feature -- Access
|
||||
Result := items_by_type_from (Current, t)
|
||||
end
|
||||
|
||||
items_by_css_id (a_id: READABLE_STRING_GENERAL): detachable LIST [CMS_WIDGET]
|
||||
items_by_css_id (a_id: READABLE_STRING_GENERAL): detachable LIST [WSF_WIDGET]
|
||||
do
|
||||
Result := items_by_css_id_from (Current, a_id)
|
||||
end
|
||||
|
||||
first_item_by_css_id (a_id: READABLE_STRING_GENERAL): detachable CMS_WIDGET
|
||||
first_item_by_css_id (a_id: READABLE_STRING_GENERAL): detachable WSF_WIDGET
|
||||
do
|
||||
if attached items_by_css_id_from (Current, a_id) as lst then
|
||||
if not lst.is_empty then
|
||||
@@ -109,7 +109,7 @@ feature -- Access
|
||||
|
||||
feature -- Change
|
||||
|
||||
insert_before (i: CMS_WIDGET; a_item: CMS_WIDGET)
|
||||
insert_before (i: WSF_WIDGET; a_item: WSF_WIDGET)
|
||||
-- Insert `i' before `a_item'
|
||||
require
|
||||
has_item (a_item)
|
||||
@@ -130,7 +130,7 @@ feature -- Change
|
||||
until
|
||||
done
|
||||
loop
|
||||
if attached {CMS_WIDGET_COMPOSITE} c.item as comp and then comp.has_item (a_item) then
|
||||
if attached {WSF_WIDGET_COMPOSITE} c.item as comp and then comp.has_item (a_item) then
|
||||
comp.insert_before (i, a_item)
|
||||
done := True
|
||||
end
|
||||
@@ -138,7 +138,7 @@ feature -- Change
|
||||
end
|
||||
end
|
||||
|
||||
insert_after (i: CMS_WIDGET; a_item: CMS_WIDGET)
|
||||
insert_after (i: WSF_WIDGET; a_item: WSF_WIDGET)
|
||||
-- Insert `i' after `a_item'
|
||||
require
|
||||
has_item (a_item)
|
||||
@@ -159,7 +159,7 @@ feature -- Change
|
||||
until
|
||||
done
|
||||
loop
|
||||
if attached {CMS_WIDGET_COMPOSITE} c.item as comp and then comp.has_item (a_item) then
|
||||
if attached {WSF_WIDGET_COMPOSITE} c.item as comp and then comp.has_item (a_item) then
|
||||
comp.insert_after (i, a_item)
|
||||
done := True
|
||||
end
|
||||
@@ -167,26 +167,26 @@ feature -- Change
|
||||
end
|
||||
end
|
||||
|
||||
extend (i: CMS_WIDGET)
|
||||
extend (i: WSF_WIDGET)
|
||||
do
|
||||
items.force (i)
|
||||
end
|
||||
|
||||
prepend (i: CMS_WIDGET)
|
||||
prepend (i: WSF_WIDGET)
|
||||
do
|
||||
items.put_front (i)
|
||||
end
|
||||
|
||||
extend_text (t: READABLE_STRING_8)
|
||||
do
|
||||
extend (create {CMS_WIDGET_TEXT}.make_with_text (t))
|
||||
extend (create {WSF_WIDGET_TEXT}.make_with_text (t))
|
||||
end
|
||||
|
||||
feature {NONE} -- Implementation: Items
|
||||
|
||||
items_by_type_from (a_container: ITERABLE [CMS_WIDGET]; a_type: TYPE [detachable ANY]): detachable ARRAYED_LIST [CMS_WIDGET]
|
||||
items_by_type_from (a_container: ITERABLE [WSF_WIDGET]; a_type: TYPE [detachable ANY]): detachable ARRAYED_LIST [WSF_WIDGET]
|
||||
local
|
||||
res: detachable ARRAYED_LIST [CMS_WIDGET]
|
||||
res: detachable ARRAYED_LIST [WSF_WIDGET]
|
||||
do
|
||||
across
|
||||
a_container as i
|
||||
@@ -196,7 +196,7 @@ feature {NONE} -- Implementation: Items
|
||||
create res.make (1)
|
||||
end
|
||||
res.force (i.item)
|
||||
elseif attached {ITERABLE [CMS_WIDGET]} i.item as l_cont then
|
||||
elseif attached {ITERABLE [WSF_WIDGET]} i.item as l_cont then
|
||||
if attached items_by_type_from (l_cont, a_type) as lst then
|
||||
if res = Void then
|
||||
res := lst
|
||||
@@ -209,15 +209,15 @@ feature {NONE} -- Implementation: Items
|
||||
Result := res
|
||||
end
|
||||
|
||||
items_by_css_id_from (a_container: ITERABLE [CMS_WIDGET]; a_id: READABLE_STRING_GENERAL): detachable ARRAYED_LIST [CMS_WIDGET]
|
||||
items_by_css_id_from (a_container: ITERABLE [WSF_WIDGET]; a_id: READABLE_STRING_GENERAL): detachable ARRAYED_LIST [WSF_WIDGET]
|
||||
local
|
||||
res: detachable ARRAYED_LIST [CMS_WIDGET]
|
||||
res: detachable ARRAYED_LIST [WSF_WIDGET]
|
||||
do
|
||||
across
|
||||
a_container as i
|
||||
loop
|
||||
if
|
||||
attached {WITH_CSS_ID} i.item as l_with_css_id and then
|
||||
attached {WSF_WITH_CSS_ID} i.item as l_with_css_id and then
|
||||
attached l_with_css_id.css_id as l_css_id and then
|
||||
l_css_id.same_string_general (a_id)
|
||||
then
|
||||
@@ -225,7 +225,7 @@ feature {NONE} -- Implementation: Items
|
||||
create res.make (1)
|
||||
end
|
||||
res.force (i.item)
|
||||
elseif attached {ITERABLE [CMS_WIDGET]} i.item as l_cont then
|
||||
elseif attached {ITERABLE [WSF_WIDGET]} i.item as l_cont then
|
||||
if attached items_by_css_id_from (l_cont, a_id) as lst then
|
||||
if res = Void then
|
||||
res := lst
|
||||
@@ -240,7 +240,7 @@ feature {NONE} -- Implementation: Items
|
||||
|
||||
feature {NONE} -- Implementation
|
||||
|
||||
items: ARRAYED_LIST [CMS_WIDGET]
|
||||
items: ARRAYED_LIST [WSF_WIDGET]
|
||||
-- name => item
|
||||
|
||||
invariant
|
||||
@@ -1,21 +1,21 @@
|
||||
note
|
||||
description: "Summary description for {CMS_WIDGET_FILLED_TABLE}."
|
||||
description: "Summary description for {WSF_WIDGET_FILLED_TABLE}."
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_WIDGET_TABLE
|
||||
WSF_WIDGET_TABLE
|
||||
|
||||
inherit
|
||||
CMS_WIDGET
|
||||
WSF_WIDGET
|
||||
|
||||
WITH_CSS_ID
|
||||
WSF_WITH_CSS_ID
|
||||
|
||||
WITH_CSS_CLASS
|
||||
WSF_WITH_CSS_CLASS
|
||||
|
||||
WITH_CSS_STYLE
|
||||
WSF_WITH_CSS_STYLE
|
||||
|
||||
ITERABLE [CMS_WIDGET_TABLE_ITEM]
|
||||
ITERABLE [WSF_WIDGET_TABLE_ITEM]
|
||||
|
||||
create
|
||||
make
|
||||
@@ -27,9 +27,9 @@ feature {NONE} -- Initialization
|
||||
create columns.make_empty
|
||||
end
|
||||
|
||||
make_from_table (tb: CMS_WIDGET_AGENT_TABLE [detachable ANY])
|
||||
make_from_table (tb: WSF_WIDGET_AGENT_TABLE [detachable ANY])
|
||||
local
|
||||
fct: like {CMS_WIDGET_AGENT_TABLE [detachable ANY]}.compute_item_function
|
||||
fct: like {WSF_WIDGET_AGENT_TABLE [detachable ANY]}.compute_item_function
|
||||
do
|
||||
make
|
||||
set_column_count (tb.column_count)
|
||||
@@ -75,7 +75,7 @@ feature {NONE} -- Initialization
|
||||
|
||||
feature -- Access
|
||||
|
||||
new_cursor: CMS_WIDGET_TABLE_ITERATION_CURSOR
|
||||
new_cursor: WSF_WIDGET_TABLE_ITERATION_CURSOR
|
||||
-- Fresh cursor associated with current structure
|
||||
do
|
||||
create Result.make (Current)
|
||||
@@ -112,10 +112,10 @@ feature -- Access
|
||||
Result := head_row_count + body_row_count + foot_row_count
|
||||
end
|
||||
|
||||
columns: ARRAY [CMS_WIDGET_TABLE_COLUMN]
|
||||
columns: ARRAY [WSF_WIDGET_TABLE_COLUMN]
|
||||
|
||||
|
||||
column (c: INTEGER): CMS_WIDGET_TABLE_COLUMN
|
||||
column (c: INTEGER): WSF_WIDGET_TABLE_COLUMN
|
||||
do
|
||||
if c > column_count then
|
||||
set_column_count (c)
|
||||
@@ -123,7 +123,7 @@ feature -- Access
|
||||
Result := columns[c]
|
||||
end
|
||||
|
||||
row (r: INTEGER): detachable CMS_WIDGET_TABLE_ROW
|
||||
row (r: INTEGER): detachable WSF_WIDGET_TABLE_ROW
|
||||
do
|
||||
if r <= head_row_count then
|
||||
if attached head_rows as lst then
|
||||
@@ -145,13 +145,13 @@ feature -- Access
|
||||
Result := across columns as c some c.item.title /= Void end
|
||||
end
|
||||
|
||||
head_rows: detachable ARRAYED_LIST [CMS_WIDGET_TABLE_ROW]
|
||||
head_rows: detachable ARRAYED_LIST [WSF_WIDGET_TABLE_ROW]
|
||||
-- thead
|
||||
|
||||
foot_rows: detachable ARRAYED_LIST [CMS_WIDGET_TABLE_ROW]
|
||||
foot_rows: detachable ARRAYED_LIST [WSF_WIDGET_TABLE_ROW]
|
||||
-- tfoot
|
||||
|
||||
rows: detachable ARRAYED_LIST [CMS_WIDGET_TABLE_ROW]
|
||||
rows: detachable ARRAYED_LIST [WSF_WIDGET_TABLE_ROW]
|
||||
-- tbody
|
||||
|
||||
feature -- Change
|
||||
@@ -163,37 +163,37 @@ feature -- Change
|
||||
rows := Void
|
||||
end
|
||||
|
||||
add_head_row (r: CMS_WIDGET_TABLE_ROW)
|
||||
add_head_row (r: WSF_WIDGET_TABLE_ROW)
|
||||
local
|
||||
lst: like head_rows
|
||||
do
|
||||
lst := head_rows
|
||||
if lst = Void then
|
||||
create {ARRAYED_LIST [CMS_WIDGET_TABLE_ROW]} lst.make (1)
|
||||
create {ARRAYED_LIST [WSF_WIDGET_TABLE_ROW]} lst.make (1)
|
||||
head_rows := lst
|
||||
end
|
||||
lst.force (r)
|
||||
end
|
||||
|
||||
add_foot_row (r: CMS_WIDGET_TABLE_ROW)
|
||||
add_foot_row (r: WSF_WIDGET_TABLE_ROW)
|
||||
local
|
||||
lst: like foot_rows
|
||||
do
|
||||
lst := foot_rows
|
||||
if lst = Void then
|
||||
create {ARRAYED_LIST [CMS_WIDGET_TABLE_ROW]} lst.make (1)
|
||||
create {ARRAYED_LIST [WSF_WIDGET_TABLE_ROW]} lst.make (1)
|
||||
foot_rows := lst
|
||||
end
|
||||
lst.force (r)
|
||||
end
|
||||
|
||||
add_row (r: CMS_WIDGET_TABLE_ROW)
|
||||
add_row (r: WSF_WIDGET_TABLE_ROW)
|
||||
local
|
||||
lst: like rows
|
||||
do
|
||||
lst := rows
|
||||
if lst = Void then
|
||||
create {ARRAYED_LIST [CMS_WIDGET_TABLE_ROW]} lst.make (1)
|
||||
create {ARRAYED_LIST [WSF_WIDGET_TABLE_ROW]} lst.make (1)
|
||||
rows := lst
|
||||
end
|
||||
lst.force (r)
|
||||
@@ -206,7 +206,7 @@ feature -- Change
|
||||
until
|
||||
columns.count = nb
|
||||
loop
|
||||
columns.force (create {CMS_WIDGET_TABLE_COLUMN}.make (columns.upper + 1), columns.upper + 1)
|
||||
columns.force (create {WSF_WIDGET_TABLE_COLUMN}.make (columns.upper + 1), columns.upper + 1)
|
||||
end
|
||||
else
|
||||
columns.remove_tail (columns.count - nb)
|
||||
@@ -225,7 +225,7 @@ feature -- Change
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
local
|
||||
l_use_tbody: BOOLEAN
|
||||
do
|
||||
@@ -269,7 +269,7 @@ feature -- Conversion
|
||||
a_html.append ("</table>")
|
||||
end
|
||||
|
||||
append_rows_to_html (lst: ITERABLE [CMS_WIDGET_TABLE_ROW]; a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_rows_to_html (lst: ITERABLE [WSF_WIDGET_TABLE_ROW]; a_theme: WSF_THEME; a_html: STRING_8)
|
||||
do
|
||||
across
|
||||
lst as r
|
||||
@@ -1,16 +1,16 @@
|
||||
note
|
||||
description: "Summary description for {CMS_WIDGET_COLUMN}."
|
||||
description: "Summary description for {WSF_WIDGET_COLUMN}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_WIDGET_TABLE_COLUMN
|
||||
WSF_WIDGET_TABLE_COLUMN
|
||||
|
||||
inherit
|
||||
WITH_CSS_CLASS
|
||||
WSF_WITH_CSS_CLASS
|
||||
|
||||
WITH_CSS_STYLE
|
||||
WSF_WITH_CSS_STYLE
|
||||
|
||||
create
|
||||
make
|
||||
@@ -37,7 +37,7 @@ feature -- Change
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_table_header_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_table_header_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
do
|
||||
a_html.append ("<th")
|
||||
append_css_class_to (a_html, Void)
|
||||
@@ -1,22 +1,22 @@
|
||||
note
|
||||
description: "Summary description for {CMS_WIDGET_TABLE_ITEM}."
|
||||
description: "Summary description for {WSF_WIDGET_TABLE_ITEM}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_WIDGET_TABLE_ITEM
|
||||
WSF_WIDGET_TABLE_ITEM
|
||||
|
||||
inherit
|
||||
CMS_WIDGET
|
||||
WSF_WIDGET
|
||||
|
||||
WITH_HTML_ATTRIBUTE
|
||||
WSF_WITH_HTML_ATTRIBUTE
|
||||
|
||||
WITH_CSS_CLASS
|
||||
WSF_WITH_CSS_CLASS
|
||||
|
||||
WITH_CSS_STYLE
|
||||
WSF_WITH_CSS_STYLE
|
||||
|
||||
ITERABLE [CMS_WIDGET]
|
||||
ITERABLE [WSF_WIDGET]
|
||||
|
||||
create
|
||||
make_with_text,
|
||||
@@ -27,7 +27,7 @@ feature {NONE} -- Initialization
|
||||
|
||||
make_with_text (a_text: READABLE_STRING_8)
|
||||
do
|
||||
make_with_content (create {CMS_WIDGET_TEXT}.make_with_text (a_text))
|
||||
make_with_content (create {WSF_WIDGET_TEXT}.make_with_text (a_text))
|
||||
end
|
||||
|
||||
make_with_text_and_css (a_text: READABLE_STRING_8; a_css_classes: detachable ITERABLE [READABLE_STRING_8])
|
||||
@@ -42,21 +42,21 @@ feature {NONE} -- Initialization
|
||||
end
|
||||
end
|
||||
|
||||
make_with_content (a_widget: CMS_WIDGET)
|
||||
make_with_content (a_widget: WSF_WIDGET)
|
||||
do
|
||||
content := a_widget
|
||||
end
|
||||
|
||||
feature -- Access
|
||||
|
||||
content: CMS_WIDGET
|
||||
content: WSF_WIDGET
|
||||
|
||||
feature -- Access
|
||||
|
||||
new_cursor: ITERATION_CURSOR [CMS_WIDGET]
|
||||
new_cursor: ITERATION_CURSOR [WSF_WIDGET]
|
||||
-- Fresh cursor associated with current structure
|
||||
local
|
||||
lst: ARRAYED_LIST [CMS_WIDGET]
|
||||
lst: ARRAYED_LIST [WSF_WIDGET]
|
||||
do
|
||||
create lst.make (1)
|
||||
lst.extend (content)
|
||||
@@ -65,7 +65,7 @@ feature -- Access
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
do
|
||||
a_html.append ("<td")
|
||||
append_css_class_to (a_html, Void)
|
||||
@@ -1,27 +1,27 @@
|
||||
note
|
||||
description: "Summary description for {CMS_WIDGET_TABLE_ITERATION_CURSOR}."
|
||||
description: "Summary description for {WSF_WIDGET_TABLE_ITERATION_CURSOR}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_WIDGET_TABLE_ITERATION_CURSOR
|
||||
WSF_WIDGET_TABLE_ITERATION_CURSOR
|
||||
|
||||
inherit
|
||||
ITERATION_CURSOR [CMS_WIDGET_TABLE_ITEM]
|
||||
ITERATION_CURSOR [WSF_WIDGET_TABLE_ITEM]
|
||||
|
||||
create
|
||||
make
|
||||
|
||||
feature {NONE} -- Initialization
|
||||
|
||||
make (a_table: CMS_WIDGET_TABLE)
|
||||
make (a_table: WSF_WIDGET_TABLE)
|
||||
do
|
||||
table := a_table
|
||||
start
|
||||
end
|
||||
|
||||
table: CMS_WIDGET_TABLE
|
||||
table: WSF_WIDGET_TABLE
|
||||
|
||||
row_index: INTEGER
|
||||
column_index: INTEGER
|
||||
@@ -35,7 +35,7 @@ feature -- Access
|
||||
forth
|
||||
end
|
||||
|
||||
item: CMS_WIDGET_TABLE_ITEM
|
||||
item: WSF_WIDGET_TABLE_ITEM
|
||||
-- Item at current cursor position.
|
||||
do
|
||||
if attached table.row (row_index) as r then
|
||||
@@ -1,18 +1,18 @@
|
||||
note
|
||||
description: "Summary description for {CMS_WIDGET_TABLE_ROW}."
|
||||
description: "Summary description for {WSF_WIDGET_TABLE_ROW}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_WIDGET_TABLE_ROW
|
||||
WSF_WIDGET_TABLE_ROW
|
||||
|
||||
inherit
|
||||
WITH_CSS_CLASS
|
||||
WSF_WITH_CSS_CLASS
|
||||
|
||||
WITH_CSS_STYLE
|
||||
WSF_WITH_CSS_STYLE
|
||||
|
||||
ITERABLE [CMS_WIDGET_TABLE_ITEM]
|
||||
ITERABLE [WSF_WIDGET_TABLE_ITEM]
|
||||
|
||||
create
|
||||
make,
|
||||
@@ -25,7 +25,7 @@ feature {NONE} -- Initialization
|
||||
create items.make (n)
|
||||
end
|
||||
|
||||
make_with_items (lst: ITERABLE [CMS_WIDGET_TABLE_ITEM])
|
||||
make_with_items (lst: ITERABLE [WSF_WIDGET_TABLE_ITEM])
|
||||
local
|
||||
n: INTEGER
|
||||
do
|
||||
@@ -40,11 +40,11 @@ feature {NONE} -- Initialization
|
||||
end
|
||||
end
|
||||
|
||||
items: ARRAYED_LIST [CMS_WIDGET_TABLE_ITEM]
|
||||
items: ARRAYED_LIST [WSF_WIDGET_TABLE_ITEM]
|
||||
|
||||
feature -- Access
|
||||
|
||||
new_cursor: ITERATION_CURSOR [CMS_WIDGET_TABLE_ITEM]
|
||||
new_cursor: ITERATION_CURSOR [WSF_WIDGET_TABLE_ITEM]
|
||||
do
|
||||
Result := items.new_cursor
|
||||
end
|
||||
@@ -54,14 +54,14 @@ feature -- Access
|
||||
Result := items.count
|
||||
end
|
||||
|
||||
item (c: INTEGER): CMS_WIDGET_TABLE_ITEM
|
||||
item (c: INTEGER): WSF_WIDGET_TABLE_ITEM
|
||||
do
|
||||
Result := items [c]
|
||||
end
|
||||
|
||||
feature -- Change
|
||||
|
||||
set_item (w: CMS_WIDGET_TABLE_ITEM; col: INTEGER)
|
||||
set_item (w: WSF_WIDGET_TABLE_ITEM; col: INTEGER)
|
||||
do
|
||||
if col > items.count then
|
||||
items.grow (col)
|
||||
@@ -69,7 +69,7 @@ feature -- Change
|
||||
until
|
||||
items.count >= col - 1
|
||||
loop
|
||||
items.force (create {CMS_WIDGET_TABLE_ITEM}.make_with_text (""))
|
||||
items.force (create {WSF_WIDGET_TABLE_ITEM}.make_with_text (""))
|
||||
end
|
||||
items.force (w)
|
||||
else
|
||||
@@ -77,19 +77,19 @@ feature -- Change
|
||||
end
|
||||
end
|
||||
|
||||
add_widget (w: CMS_WIDGET)
|
||||
add_widget (w: WSF_WIDGET)
|
||||
do
|
||||
add_item (create {CMS_WIDGET_TABLE_ITEM}.make_with_content (w))
|
||||
add_item (create {WSF_WIDGET_TABLE_ITEM}.make_with_content (w))
|
||||
end
|
||||
|
||||
force, add_item (w: CMS_WIDGET_TABLE_ITEM)
|
||||
force, add_item (w: WSF_WIDGET_TABLE_ITEM)
|
||||
do
|
||||
items.force (w)
|
||||
end
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
do
|
||||
a_html.append ("<tr")
|
||||
append_css_class_to (a_html, Void)
|
||||
@@ -1,14 +1,14 @@
|
||||
note
|
||||
description: "Summary description for {CMS_WIDGET_TEXT}."
|
||||
description: "Summary description for {WSF_WIDGET_TEXT}."
|
||||
author: ""
|
||||
date: "$Date$"
|
||||
revision: "$Revision$"
|
||||
|
||||
class
|
||||
CMS_WIDGET_TEXT
|
||||
WSF_WIDGET_TEXT
|
||||
|
||||
inherit
|
||||
CMS_WIDGET
|
||||
WSF_WIDGET
|
||||
|
||||
create
|
||||
make_with_text
|
||||
@@ -33,7 +33,7 @@ feature -- Change
|
||||
|
||||
feature -- Conversion
|
||||
|
||||
append_to_html (a_theme: CMS_THEME; a_html: STRING_8)
|
||||
append_to_html (a_theme: WSF_THEME; a_html: STRING_8)
|
||||
do
|
||||
a_html.append (text)
|
||||
end
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="ISO-8859-1"?>
|
||||
<system xmlns="http://www.eiffel.com/developers/xml/configuration-1-8-0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.eiffel.com/developers/xml/configuration-1-8-0 http://www.eiffel.com/developers/xml/configuration-1-8-0.xsd" name="css" uuid="1A3423E5-9B5B-431D-A8C3-1CF638F74B6F" library_target="css">
|
||||
<target name="css">
|
||||
<system xmlns="http://www.eiffel.com/developers/xml/configuration-1-8-0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.eiffel.com/developers/xml/configuration-1-8-0 http://www.eiffel.com/developers/xml/configuration-1-8-0.xsd" name="wsf_html" uuid="6AAAE037-7E66-4F5D-BED0-0042245C26BC" library_target="wsf_html">
|
||||
<target name="wsf_html">
|
||||
<root all_classes="true"/>
|
||||
<file_rule>
|
||||
<exclude>/.git$</exclude>
|
||||
@@ -10,6 +10,10 @@
|
||||
<option warning="true" full_class_checking="true" is_attached_by_default="true" void_safety="all" syntax="standard">
|
||||
</option>
|
||||
<library name="base" location="$ISE_LIBRARY/library/base/base-safe.ecf"/>
|
||||
<cluster name="src" location="." recursive="true"/>
|
||||
<library name="encoder" location="../../text/encoder/encoder-safe.ecf"/>
|
||||
<library name="wsf" location="../wsf/wsf-safe.ecf"/>
|
||||
<cluster name="form" location="./form" recursive="true"/>
|
||||
<cluster name="widget" location="./widget" recursive="true"/>
|
||||
<cluster name="css" location="./css" recursive="true"/>
|
||||
</target>
|
||||
</system>
|
||||
@@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="ISO-8859-1"?>
|
||||
<system xmlns="http://www.eiffel.com/developers/xml/configuration-1-8-0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.eiffel.com/developers/xml/configuration-1-8-0 http://www.eiffel.com/developers/xml/configuration-1-8-0.xsd" name="css" uuid="1A3423E5-9B5B-431D-A8C3-1CF638F74B6F" library_target="css">
|
||||
<target name="css">
|
||||
<system xmlns="http://www.eiffel.com/developers/xml/configuration-1-8-0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.eiffel.com/developers/xml/configuration-1-8-0 http://www.eiffel.com/developers/xml/configuration-1-8-0.xsd" name="wsf_html" uuid="6AAAE037-7E66-4F5D-BED0-0042245C26BC" library_target="wsf_html">
|
||||
<target name="wsf_html">
|
||||
<root all_classes="true"/>
|
||||
<file_rule>
|
||||
<exclude>/.git$</exclude>
|
||||
@@ -10,6 +10,10 @@
|
||||
<option warning="true" full_class_checking="true" void_safety="none" syntax="standard">
|
||||
</option>
|
||||
<library name="base" location="$ISE_LIBRARY/library/base/base.ecf"/>
|
||||
<cluster name="src" location="." recursive="true"/>
|
||||
<library name="encoder" location="../../text/encoder/encoder.ecf"/>
|
||||
<library name="wsf" location="../wsf/wsf.ecf"/>
|
||||
<cluster name="form" location="./form" recursive="true"/>
|
||||
<cluster name="widget" location="./widget" recursive="true"/>
|
||||
<cluster name="css" location="./css" recursive="true"/>
|
||||
</target>
|
||||
</system>
|
||||
Reference in New Issue
Block a user