Slow down fetching

This commit is contained in:
YNH Webdev
2013-09-16 00:01:31 +02:00
parent fccb6776b0
commit 1da678f726
3 changed files with 4 additions and 4 deletions

View File

@@ -75,7 +75,7 @@ feature
container.add_control (form)
--Progress bar
container.add_control (create {WSF_BASIC_CONTROL}.make_with_body("h4","","Number1/Number2"))
container.add_control (create {WSF_BASIC_CONTROL}.make_with_body("h4","","Autoincrementing progressbar"))
create source.make
create progress.make_progress_with_source ("progress1", source)
source.set_control (progress)
@@ -88,7 +88,7 @@ feature
do
form.validate
if form.is_valid then
progress.set_progress ((textbox1.text.to_integer_64 / textbox2.text.to_integer_64 * 100).ceiling)
--progress.set_progress ((textbox1.text.to_integer_64 / textbox2.text.to_integer_64 * 100).ceiling)
text := textbox1.text + " + " + textbox2.text + " = " + (textbox1.text.to_integer_64 + textbox2.text.to_integer_64).out
text.append ("<ul>")
across

View File

@@ -259,7 +259,7 @@ class WSF_PROGRESS_CONTROL extends WSF_CONTROL
self = @
runfetch= ()->
self.fetch()
setInterval(runfetch, 100)
setInterval(runfetch, 5000)
fetch: ()->
trigger_callback(@control_name, 'progress_fetch')

View File

@@ -483,7 +483,7 @@
runfetch = function() {
return self.fetch();
};
return setInterval(runfetch, 100);
return setInterval(runfetch, 5000);
};
WSF_PROGRESS_CONTROL.prototype.fetch = function() {