diff --git a/library/server/wsf_js_widget/autocompletion/wsf_simple_autocompletion.e b/library/server/wsf_js_widget/autocompletion/wsf_simple_autocompletion.e index 10b94c99..cdbc4654 100644 --- a/library/server/wsf_js_widget/autocompletion/wsf_simple_autocompletion.e +++ b/library/server/wsf_js_widget/autocompletion/wsf_simple_autocompletion.e @@ -33,7 +33,7 @@ feature -- Implementation loop if c.item.as_lower.has_substring (input.as_lower) then create o.make - o.put (create {JSON_STRING}.make_json (c.item), "value") + o.put (create {JSON_STRING}.make_json(c.item), "value") Result.add (o) end end diff --git a/library/server/wsf_js_widget/grid/wsf_pagable_datasource.e b/library/server/wsf_js_widget/grid/wsf_pagable_datasource.e index 547b7269..fa2ff886 100644 --- a/library/server/wsf_js_widget/grid/wsf_pagable_datasource.e +++ b/library/server/wsf_js_widget/grid/wsf_pagable_datasource.e @@ -26,10 +26,10 @@ feature -- Update event update do if attached on_update_agent as a then - a.call ([]) + a.call (Void) end if attached on_update_page_agent as a then - a.call ([]) + a.call (Void) end end @@ -41,21 +41,21 @@ feature --States -- Return state which contains the current html and if there is an event handle attached do Result := Precursor - Result.put (create {JSON_NUMBER}.make_integer (page), create {JSON_STRING}.make_json ("page")) - Result.put (create {JSON_NUMBER}.make_integer (page_size), create {JSON_STRING}.make_json ("page_size")) - Result.put (create {JSON_NUMBER}.make_integer (row_count), create {JSON_STRING}.make_json ("row_count")) + Result.put (create {JSON_NUMBER}.make_integer (page), "page") + Result.put (create {JSON_NUMBER}.make_integer (page_size), "page_size") + Result.put (create {JSON_NUMBER}.make_integer (row_count), "row_count") end set_state (new_state: JSON_OBJECT) do Precursor (new_state) - if attached {JSON_NUMBER} new_state.item (create {JSON_STRING}.make_json ("page")) as new_page then + if attached {JSON_NUMBER} new_state.item ("page") as new_page then page := new_page.item.to_integer end - if attached {JSON_NUMBER} new_state.item (create {JSON_STRING}.make_json ("page_size")) as new_page_size then + if attached {JSON_NUMBER} new_state.item ("page_size") as new_page_size then page_size := new_page_size.item.to_integer end - if attached {JSON_NUMBER} new_state.item (create {JSON_STRING}.make_json ("row_count")) as new_row_count then + if attached {JSON_NUMBER} new_state.item ("row_count") as new_row_count then row_count := new_row_count.item.to_integer end end diff --git a/library/server/wsf_js_widget/grid/wsf_pagination_control.e b/library/server/wsf_js_widget/grid/wsf_pagination_control.e index e3390989..238aa9ff 100644 --- a/library/server/wsf_js_widget/grid/wsf_pagination_control.e +++ b/library/server/wsf_js_widget/grid/wsf_pagination_control.e @@ -40,12 +40,12 @@ feature --EVENT HANDLING handle_callback (cname: STRING; event: STRING; event_parameter: detachable STRING) do - if Current.control_name.is_equal (cname) then - if event.is_equal ("next") then + if Current.control_name.same_string (cname) then + if event.same_string ("next") then datasource.set_page (datasource.page + 1) - elseif event.is_equal ("prev") then + elseif event.same_string ("prev") then datasource.set_page (datasource.page - 1) - elseif event.is_equal ("goto") then + elseif event.same_string ("goto") then if attached event_parameter as p and then attached p.to_integer as i then datasource.set_page (i) end diff --git a/library/server/wsf_js_widget/input/wsf_autocomplete_control.e b/library/server/wsf_js_widget/input/wsf_autocomplete_control.e index c6f1c586..0c4db9ad 100644 --- a/library/server/wsf_js_widget/input/wsf_autocomplete_control.e +++ b/library/server/wsf_js_widget/input/wsf_autocomplete_control.e @@ -40,7 +40,7 @@ feature -- State state: JSON_OBJECT do Result := Precursor {WSF_INPUT_CONTROL} - Result.put (create {JSON_STRING}.make_json (template), create {JSON_STRING}.make_json ("template")) + Result.put (create {JSON_STRING}.make_json (template), "template") end feature -- Callback @@ -48,8 +48,8 @@ feature -- Callback handle_callback (cname: STRING; event: STRING; event_parameter: detachable STRING) do Precursor {WSF_INPUT_CONTROL} (cname, event, event_parameter) - if cname.is_equal (control_name) and event.is_equal ("autocomplete") then - state_changes.put (create_json_list.item ([text]), create {JSON_STRING}.make_json ("suggestions")) + if cname.same_string (control_name) and event.same_string ("autocomplete") then + state_changes.put (create_json_list.item ([text]), "suggestions") end end diff --git a/library/server/wsf_js_widget/input/wsf_input_control.e b/library/server/wsf_js_widget/input/wsf_input_control.e index 2c729508..7156aa17 100644 --- a/library/server/wsf_js_widget/input/wsf_input_control.e +++ b/library/server/wsf_js_widget/input/wsf_input_control.e @@ -28,7 +28,7 @@ feature {WSF_PAGE_CONTROL, WSF_CONTROL} -- STATE MANAGEMENT set_state (new_state: JSON_OBJECT) -- Restore text from json do - if attached {JSON_STRING} new_state.item (create {JSON_STRING}.make_json ("text")) as new_text then + if attached {JSON_STRING} new_state.item ("text") as new_text then text := new_text.unescaped_string_32 end end @@ -37,8 +37,8 @@ feature {WSF_PAGE_CONTROL, WSF_CONTROL} -- STATE MANAGEMENT -- Return state which contains the current text and if there is an event handle attached do create Result.make - Result.put (create {JSON_STRING}.make_json (text), create {JSON_STRING}.make_json ("text")) - Result.put (create {JSON_BOOLEAN}.make_boolean (attached change_event), create {JSON_STRING}.make_json ("callback_change")) + Result.put (create {JSON_STRING}.make_json (text), "text") + Result.put (create {JSON_BOOLEAN}.make_boolean (attached change_event), "callback_change") end feature --EVENT HANDLING @@ -51,9 +51,9 @@ feature --EVENT HANDLING handle_callback (cname: STRING; event: STRING; event_parameter: detachable STRING) do - if Current.control_name.is_equal (cname) and attached change_event as cevent then - if event.is_equal ("change") then - cevent.call ([]) + if Current.control_name.same_string (cname) and attached change_event as cevent then + if event.same_string ("change") then + cevent.call (Void) end end end @@ -67,9 +67,9 @@ feature -- Implementation set_text (t: STRING) do - if not t.is_equal (text) then + if not t.same_string (text) then text := t - state_changes.replace (create {JSON_STRING}.make_json (text), create {JSON_STRING}.make_json ("text")) + state_changes.replace (create {JSON_STRING}.make_json (text), "text") end end diff --git a/library/server/wsf_js_widget/progressbar/wsf_progress_control.e b/library/server/wsf_js_widget/progressbar/wsf_progress_control.e index 1d5f7779..dcd0fb95 100644 --- a/library/server/wsf_js_widget/progressbar/wsf_progress_control.e +++ b/library/server/wsf_js_widget/progressbar/wsf_progress_control.e @@ -33,7 +33,7 @@ feature -- State handling set_state (new_state: JSON_OBJECT) do - if attached {JSON_NUMBER} new_state.item (create {JSON_STRING}.make_json ("progress")) as new_progress then + if attached {JSON_NUMBER} new_state.item ("progress") as new_progress then progress := new_progress.item.to_integer end end @@ -48,8 +48,8 @@ feature -- Event handling handle_callback (cname: STRING; event: STRING; event_parameter: detachable STRING) do - if cname.is_equal (control_name) and event.is_equal ("progress_fetch") then - state_changes.put (create {JSON_NUMBER}.make_integer (progress_value), create {JSON_STRING}.make_json ("progress")) + if cname.same_string (control_name) and event.same_string ("progress_fetch") then + state_changes.put (create {JSON_NUMBER}.make_integer (progress_value), "progress") end end @@ -71,7 +71,7 @@ feature --Change progress no_progress_source: not (attached progress_source) do progress := p - state_changes.put (create {JSON_NUMBER}.make_integer (progress), create {JSON_STRING}.make_json ("progress")) + state_changes.put (create {JSON_NUMBER}.make_integer (progress), "progress") end feature diff --git a/library/server/wsf_js_widget/validator/wsf_max_validator.e b/library/server/wsf_js_widget/validator/wsf_max_validator.e index f766a41d..d886a82d 100644 --- a/library/server/wsf_js_widget/validator/wsf_max_validator.e +++ b/library/server/wsf_js_widget/validator/wsf_max_validator.e @@ -37,7 +37,7 @@ feature state: JSON_OBJECT do Result := Precursor - Result.put (create {JSON_NUMBER}.make_integer (max), create {JSON_STRING}.make_json ("max")) + Result.put (create {JSON_NUMBER}.make_integer (max), "max") end max: INTEGER diff --git a/library/server/wsf_js_widget/validator/wsf_min_validator.e b/library/server/wsf_js_widget/validator/wsf_min_validator.e index 6e225aa1..62233a13 100644 --- a/library/server/wsf_js_widget/validator/wsf_min_validator.e +++ b/library/server/wsf_js_widget/validator/wsf_min_validator.e @@ -37,7 +37,7 @@ feature state: JSON_OBJECT do Result := Precursor - Result.put (create {JSON_NUMBER}.make_integer (min), create {JSON_STRING}.make_json ("min")) + Result.put (create {JSON_NUMBER}.make_integer (min), "min") end min: INTEGER diff --git a/library/server/wsf_js_widget/validator/wsf_regexp_validator.e b/library/server/wsf_js_widget/validator/wsf_regexp_validator.e index 5dcc6e7c..0618199b 100644 --- a/library/server/wsf_js_widget/validator/wsf_regexp_validator.e +++ b/library/server/wsf_js_widget/validator/wsf_regexp_validator.e @@ -42,9 +42,9 @@ feature state: JSON_OBJECT do create Result.make - Result.put (create {JSON_STRING}.make_json ("WSF_REGEXP_VALIDATOR"), create {JSON_STRING}.make_json ("name")) - Result.put (create {JSON_STRING}.make_json (regexp_string), create {JSON_STRING}.make_json ("expression")) - Result.put (create {JSON_STRING}.make_json (error), create {JSON_STRING}.make_json ("error")) + Result.put (create {JSON_STRING}.make_json ("WSF_REGEXP_VALIDATOR"), "name") + Result.put (create {JSON_STRING}.make_json (regexp_string), "expression") + Result.put (create {JSON_STRING}.make_json (error), "error") end regexp_string: STRING diff --git a/library/server/wsf_js_widget/validator/wsf_validator.e b/library/server/wsf_js_widget/validator/wsf_validator.e index ad3f27bd..599d9e66 100644 --- a/library/server/wsf_js_widget/validator/wsf_validator.e +++ b/library/server/wsf_js_widget/validator/wsf_validator.e @@ -19,8 +19,8 @@ feature state: JSON_OBJECT do create Result.make - Result.put (create {JSON_STRING}.make_json (generator), create {JSON_STRING}.make_json ("name")) - Result.put (create {JSON_STRING}.make_json (error), create {JSON_STRING}.make_json ("error")) + Result.put (create {JSON_STRING}.make_json (generator), "name") + Result.put (create {JSON_STRING}.make_json (error), "error") end is_valid (input: G): BOOLEAN diff --git a/library/server/wsf_js_widget/webcontrol/wsf_button_control.e b/library/server/wsf_js_widget/webcontrol/wsf_button_control.e index cfbbbf3f..2a22e4a0 100644 --- a/library/server/wsf_js_widget/webcontrol/wsf_button_control.e +++ b/library/server/wsf_js_widget/webcontrol/wsf_button_control.e @@ -29,7 +29,7 @@ feature {WSF_PAGE_CONTROL, WSF_CONTROL} -- STATE MANAGEMENT set_state (new_state: JSON_OBJECT) -- Restore text from json do - if attached {JSON_STRING} new_state.item (create {JSON_STRING}.make_json ("text")) as new_text then + if attached {JSON_STRING} new_state.item ("text") as new_text then text := new_text.unescaped_string_32 end end @@ -38,8 +38,8 @@ feature {WSF_PAGE_CONTROL, WSF_CONTROL} -- STATE MANAGEMENT -- Return state which contains the current text and if there is an event handle attached do create Result.make - Result.put (create {JSON_STRING}.make_json (text), create {JSON_STRING}.make_json ("text")) - Result.put (create {JSON_BOOLEAN}.make_boolean (attached click_event), create {JSON_STRING}.make_json ("callback_click")) + Result.put (create {JSON_STRING}.make_json (text), "text") + Result.put (create {JSON_BOOLEAN}.make_boolean (attached click_event), "callback_click") end feature --EVENT HANDLING @@ -52,8 +52,8 @@ feature --EVENT HANDLING handle_callback (cname: STRING; event: STRING; event_parameter: detachable STRING) do - if Current.control_name.is_equal (cname) and attached click_event as cevent then - cevent.call ([]) + if Current.control_name.same_string (cname) and attached click_event as cevent then + cevent.call (Void) end end @@ -66,9 +66,9 @@ feature set_text (t: STRING) do - if not t.is_equal (text) then + if not t.same_string (text) then text := t - state_changes.replace (create {JSON_STRING}.make_json (text), create {JSON_STRING}.make_json ("text")) + state_changes.replace (create {JSON_STRING}.make_json (text), "text") end end diff --git a/library/server/wsf_js_widget/webcontrol/wsf_form_element_control.e b/library/server/wsf_js_widget/webcontrol/wsf_form_element_control.e index 96c15211..6621988a 100644 --- a/library/server/wsf_js_widget/webcontrol/wsf_form_element_control.e +++ b/library/server/wsf_js_widget/webcontrol/wsf_form_element_control.e @@ -128,7 +128,7 @@ feature -- Validation set_error (e: STRING) do error := e - state_changes.replace (create {JSON_STRING}.make_json (e), create {JSON_STRING}.make_json ("error")) + state_changes.replace (create {JSON_STRING}.make_json (e), "error") end validate diff --git a/library/server/wsf_js_widget/webcontrol/wsf_html_control.e b/library/server/wsf_js_widget/webcontrol/wsf_html_control.e index f8d1d17f..2193c801 100644 --- a/library/server/wsf_js_widget/webcontrol/wsf_html_control.e +++ b/library/server/wsf_js_widget/webcontrol/wsf_html_control.e @@ -27,7 +27,7 @@ feature {WSF_PAGE_CONTROL, WSF_CONTROL} -- STATE MANAGEMENT set_state (new_state: JSON_OBJECT) -- Restore html from json do - if attached {JSON_STRING} new_state.item (create {JSON_STRING}.make_json ("html")) as new_html then + if attached {JSON_STRING} new_state.item ("html") as new_html then html := new_html.unescaped_string_32 end end @@ -36,7 +36,7 @@ feature {WSF_PAGE_CONTROL, WSF_CONTROL} -- STATE MANAGEMENT -- Return state which contains the current html and if there is an event handle attached do create Result.make - Result.put (create {JSON_STRING}.make_json (html), create {JSON_STRING}.make_json ("html")) + Result.put (create {JSON_STRING}.make_json (html), "html") end feature --EVENT HANDLING @@ -54,9 +54,9 @@ feature -- Implementation set_html (t: STRING) do - if not t.is_equal (html) then + if not t.same_string (html) then html := t - state_changes.replace (create {JSON_STRING}.make_json (html), create {JSON_STRING}.make_json ("html")) + state_changes.replace (create {JSON_STRING}.make_json (html), "html") end end