summaryrefslogtreecommitdiff
path: root/framework/Web/Javascripts/extended
diff options
context:
space:
mode:
authorwei <>2006-02-01 07:08:55 +0000
committerwei <>2006-02-01 07:08:55 +0000
commit6f692501612bd24212f625c94427dfc5dcf17af8 (patch)
tree81c8cc22c63028a4d342ee37be19362c438d7522 /framework/Web/Javascripts/extended
parent5682cc56a4c703408dd927bda629ab36824dae09 (diff)
Update js library.
Diffstat (limited to 'framework/Web/Javascripts/extended')
-rw-r--r--framework/Web/Javascripts/extended/builder.js23
1 files changed, 23 insertions, 0 deletions
diff --git a/framework/Web/Javascripts/extended/builder.js b/framework/Web/Javascripts/extended/builder.js
new file mode 100644
index 00000000..f6c33bf6
--- /dev/null
+++ b/framework/Web/Javascripts/extended/builder.js
@@ -0,0 +1,23 @@
+Object.extend(Builder,
+{
+ exportTags:function()
+ {
+ var tags=["BUTTON","TT","PRE","H1","H2","H3","BR","CANVAS","HR","LABEL","TEXTAREA","FORM","STRONG","SELECT","OPTION","OPTGROUP","LEGEND","FIELDSET","P","UL","OL","LI","TD","TR","THEAD","TBODY","TFOOT","TABLE","TH","INPUT","SPAN","A","DIV","IMG"];
+ tags.each(function(tag)
+ {
+ window[tag]=function()
+ {
+ var args=$A(arguments);
+ if(args.length==0)
+ return Builder.node(tag,null);
+ if(args.length==1)
+ return Builder.node(tag,args[1]);
+ if(args.length>1)
+ return Builder.node(tag,args.shift(),args);
+
+ };
+ });
+ }
+});
+
+Builder.exportTags();