From a3e8ce8eb1c4e2d1482a22d3a7e0dba7f4ff3201 Mon Sep 17 00:00:00 2001 From: David Cramer Date: Fri, 22 Apr 2011 14:59:59 -0700 Subject: Basic support for toggling everywhere correctly --- debug_toolbar/panels/profiling.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'debug_toolbar/panels') diff --git a/debug_toolbar/panels/profiling.py b/debug_toolbar/panels/profiling.py index d0ea2c1..68aafb7 100644 --- a/debug_toolbar/panels/profiling.py +++ b/debug_toolbar/panels/profiling.py @@ -147,9 +147,11 @@ class ProfilingDebugPanel(DebugPanel): def add_node(self, func_list, func, max_depth, cum_time=0.1): func_list.append(func) + func.has_subfuncs = False if func.depth < max_depth: for subfunc in func.subfuncs(): if subfunc.stats[3] >= cum_time: + func.has_subfuncs = True self.add_node(func_list, subfunc, max_depth, cum_time=cum_time) def content(self): -- cgit v1.2.3