summaryrefslogtreecommitdiff
path: root/framework/Web/Javascripts/js/prado.js
diff options
context:
space:
mode:
authorwei <>2006-05-01 01:24:11 +0000
committerwei <>2006-05-01 01:24:11 +0000
commit884af5e651e9157dfc406fd476a51d46279a8721 (patch)
tree8de5390ef7b7c01f12f65c994c3f9d34f7dcc249 /framework/Web/Javascripts/js/prado.js
parentffd18cc7426be03a0fb8797a451d224bd97582ed (diff)
Fixed focus error.
Diffstat (limited to 'framework/Web/Javascripts/js/prado.js')
-rw-r--r--framework/Web/Javascripts/js/prado.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/framework/Web/Javascripts/js/prado.js b/framework/Web/Javascripts/js/prado.js
index d80f984d..498a6cf7 100644
--- a/framework/Web/Javascripts/js/prado.js
+++ b/framework/Web/Javascripts/js/prado.js
@@ -256,7 +256,7 @@ selection[method](isList?element:el,value);},click:function(element)
{var el=$(element);if(!el)return;if(document.createEvent)
{var evt=document.createEvent('HTMLEvents');evt.initEvent('click',true,true);el.dispatchEvent(evt);}
else if(el.fireEvent)
-{el.fireEvent('onclick');if(isFunction(el.onclick))
+{el.fireEvent('onclick');if(typeof(el.onclick)=="function")
el.onclick();}},setAttribute:function(element,attribute,value)
{var el=$(element);if(attribute=="disabled"&&value==false)
el.removeAttribute(attribute);else
@@ -265,7 +265,7 @@ el.setAttribute(attribute,value);},setOptions:function(element,options)
{while(el.length>0)
el.remove(0);for(var i=0;i<options.length;i++)
el.options[el.options.length]=new Option(options[i][0],options[i][1]);}},focus:function(element)
-{var obj=$(element);if(isObject(obj)&&isdef(obj.focus))
+{var obj=$(element);if(typeof(obj)!="undefined"&&typeof(obj.focus)!="undefined")
setTimeout(function(){obj.focus();},100);return false;}}
Prado.Element.Selection={inputValue:function(el,value)
{switch(el.type.toLowerCase())