diff options
author | Andreas Gohr <andi@splitbrain.org> | 2016-02-26 20:50:36 +0100 |
---|---|---|
committer | Andreas Gohr <andi@splitbrain.org> | 2016-02-26 20:50:36 +0100 |
commit | b288bde8c9db9190a39be1beb6f0a6ddfde2ad14 (patch) | |
tree | cda0d79f6307803b61cb06b3f8995295552ef2a0 /script.js | |
parent | cbc3610a1d15feae4b1fb006e2ea2fba2648f49b (diff) | |
download | xdebug-trace-tree-b288bde8c9db9190a39be1beb6f0a6ddfde2ad14.zip xdebug-trace-tree-b288bde8c9db9190a39be1beb6f0a6ddfde2ad14.tar.gz xdebug-trace-tree-b288bde8c9db9190a39be1beb6f0a6ddfde2ad14.tar.bz2 |
allow collapsing all functions of the same name
Diffstat (limited to 'script.js')
-rw-r--r-- | script.js | 13 |
1 files changed, 12 insertions, 1 deletions
@@ -1,7 +1,7 @@ $(function(){ - $('div.d').click(function (e) { + $('div.d, div.f').click(function (e) { if (e.target !== this) return; $(this).toggleClass('hide'); e.preventDefault(); @@ -18,4 +18,15 @@ $(function(){ $('#internal').change(function(){ $('div.i').toggle(); }); + + $('span.name').click(function(e){ + if (e.target !== this) return; + + var $fn = $(this); + var name = $(this).text(); + $("span.name:contains('"+name+"')").closest('div.f').toggleClass('hide'); + + e.preventDefault(); + e.stopPropagation(); + }); });
\ No newline at end of file |