Login | Register
My pages Projects Community openCollabNet

Discussions > cvs > CVS update: /sstree/www/

sstree
Discussion topic

Back to topic list

CVS update: /sstree/www/

Reply

Author anoncvs
Full name anonymous CVS access
Date 2003-09-01 11:01:01 PDT
Message User: jrobbins
Date: 03/09/01 11:01:01

Modified
 /sstree/www/
  example4.html

Log
 added comments
 tried to resolve issue 1

File Changes:

Directory: /sstree/www/
=======================

File [changed]: example4.html
Url: http://sstree.tigris​.org/source/browse/s​stree/www/example4.h​tml.diff?r1=1.12​&r2=1.13
Delta lines: +8 -7
-------------------
--- example4.html 25 Jun 2003 23:48:05 -0000 1.12
+++ example4.html 1 Sep 2003 18:01:01 -0000 1.13
@@ -19,10 +19,10 @@
  elm.style.backgroundImage = "url(/branding/image​s/sstree/folder-clos​ed.gif)";
  var newDisplay = "none";
  var thisID = elm.parentNode.paren​tNode.parentNode.id + "-";
- var matchDirectChildrenOnly = false;
+ // Are we expanding or contracting? If the first child is hidden, we expand
  for (var i = 0; i < rows.length; i++) {
    var r = rows[i];
- if (matchStart(r.id, thisID, matchDirectChildrenOnly)) {
+ if (matchStart(r.id, thisID, true)) {
     if (r.style.display == "none") {
      if (document.all) newDisplay = "block"; //IE4+ specific code
      else newDisplay = "table-row"; //Netscape and Mozilla
@@ -31,14 +31,15 @@
     break;
    }
  }
- if (newDisplay != "none") {
- matchDirectChildrenOnly = true;
- }
+
+ // When expanding, only expand one level. Collapse all desendants.
+ var matchDirectChildrenOnly = (newDisplay != "none");
+
  for (var j = 0; j < rows.length; j++) {
    var s = rows[j];
    if (matchStart(s.id, thisID, matchDirectChildrenOnly)) {
      s.style.display = newDisplay;
- s.style.backgroundImage = "url(/branding/image​s/sstree/folder-clos​ed.gif)";
+// s.style.backgroundImage = "url(/branding/image​s/sstree/folder-clos​ed.gif)";
    }
  }
 }




--------------------​--------------------​--------------------​---------
To unsubscribe, e-mail: cvs-unsubscribe@sstr​ee.tigris.org
For additional commands, e-mail: cvs-help at sstree dot tigris dot org

« Previous message in topic | 1 of 1 | Next message in topic »

Messages

Show all messages in topic

CVS update: /sstree/www/ anoncvs anonymous CVS access 2003-09-01 11:01:01 PDT
Messages per page: