From 74a277c2d7ac5416c3b55565e6d5e8e5a15b389d Mon Sep 17 00:00:00 2001 From: Michael Krelin Date: Fri, 29 Sep 2006 23:02:49 +0000 Subject: code beauty: mass-assignment of xul elements to member variables git-svn-id: http://svn.klever.net/kin/fireflix/trunk@169 fe716a7a-6dde-0310-88d9-d003556173a8 --- (limited to 'content/util.js') diff --git a/content/util.js b/content/util.js index 5af0978..c4af09e 100644 --- a/content/util.js +++ b/content/util.js @@ -59,3 +59,12 @@ function xp_node(xp,x) { return rv.singleNodeValue; } +/* + * pull in elements into documents as a member variables + */ +function pull_elements(th,d,els) { + for(var e in els) { + var en=els[e]; + th[en] = d.getElementById(en); + } +} -- cgit v0.9.0.2