From 8423cda014c6aee9fb3a3f7ebe78bc0465e7355f Mon Sep 17 00:00:00 2001 From: cash Date: Sat, 22 Jan 2011 20:33:28 +0000 Subject: finished the first pass on the pages plugin for using the new HTML/CSS git-svn-id: http://code.elgg.org/elgg/trunk@7904 36083f99-b078-4883-b0ff-0f9b5a30f544 --- .../jquery-treeview/jquery.treeview.async.js | 110 +++++++++++++++++++++ 1 file changed, 110 insertions(+) create mode 100644 mod/pages/vendors/jquery-treeview/jquery.treeview.async.js (limited to 'mod/pages/vendors/jquery-treeview/jquery.treeview.async.js') diff --git a/mod/pages/vendors/jquery-treeview/jquery.treeview.async.js b/mod/pages/vendors/jquery-treeview/jquery.treeview.async.js new file mode 100644 index 000000000..005231054 --- /dev/null +++ b/mod/pages/vendors/jquery-treeview/jquery.treeview.async.js @@ -0,0 +1,110 @@ +/* + * Async Treeview 0.1 - Lazy-loading extension for Treeview + * + * http://bassistance.de/jquery-plugins/jquery-plugin-treeview/ + * + * Copyright (c) 2007 Jörn Zaefferer + * + * Dual licensed under the MIT and GPL licenses: + * http://www.opensource.org/licenses/mit-license.php + * http://www.gnu.org/licenses/gpl.html + * + * Revision: $Id$ + * + */ + +;(function($) { + +function load(settings, root, child, container) { + function createNode(parent) { + var current = $("
  • ").attr("id", this.id || "").html("" + this.text + "").appendTo(parent); + if (this.classes) { + current.children("span").addClass(this.classes); + } + if (this.expanded) { + current.addClass("open"); + } + if (this.hasChildren || this.children && this.children.length) { + var branch = $("