Exemplo n.º 1
0
        //==================================================
        void updateTreeNodes(allocTreeNode node)
        {
            for (int i = 0; i < node.Nodes.Count; i++)
            {
                allocTreeNode knode = node.Nodes[i] as allocTreeNode;
                if (knode == null)
                {
                    continue;
                }

                updateTreeNodes(knode);
            }



            node.accumulatedSamples.Clear();
            node.accumulateSamples(node.accumulatedSamples);

            node.Text = node.getFullText();

            node.mFiltered = checkFilter(node);

            if (mFilterColorOnly.Checked)
            {
                if (node.mFiltered)
                {
                    node.ForeColor = Color.Blue;
                }
                else
                {
                    node.ForeColor = Color.LightGray;
                }
            }
        }
Exemplo n.º 2
0
            public string toClipboardStringOneLevel()
            {
                string outString = "";


                Stack <string> parentStrings = new Stack <string>();
                //walk parents of me.
                allocTreeNode parent = (allocTreeNode)this.Parent;

                while (parent != null)
                {
                    parentStrings.Push(parent.getFileLineFunctionText() + ":" + "    [" + MemoryNumber.convert(getInclusiveMemory()) + "]");
                    parent = (allocTreeNode)parent.Parent;
                }

                parentStrings.Pop();//we don't care about the topmost entry

                while (parentStrings.Count != 0)
                {
                    outString += parentStrings.Pop() + "\n";
                }



                outString += getFullText();



                for (int i = 0; i < Nodes.Count; i++)
                {
                    allocTreeNode knode = Nodes[i] as allocTreeNode;
                    if (knode == null)
                    {
                        continue;
                    }

                    outString += "\n" + knode.getFullText();
                }



                return(outString);
            }