コード例 #1
0
        private Node CreateFileNode(PatchPartContext part)
        {
            Node node = new Node(part.FileName)
            {
                CheckBoxVisible = true, Checked = true
            };
            ElementStyle style = new ElementStyle();

            style.TextAlignment = eStyleTextAlignment.Far;
            node.Cells.Add(new Cell(part.Type.ToString(), style));
            node.Cells.Add(new Cell(part.NewFileLength.ToString("n0"), style));
            node.Cells.Add(new Cell(part.NewChecksum.ToString("x8"), style));
            node.Cells.Add(new Cell(part.OldChecksum.ToString("x8"), style));
            if (part.Type == 1)
            {
                node.Cells.Add(new Cell(part.Action0 + "|" + part.Action1 + "|" + part.Action2, style));
            }
            node.Tag = part;
            return(node);
        }
コード例 #2
0
        private Node CreateFileNode(PatchPartContext part)
        {
            Node node = new Node(part.FileName)
            {
                CheckBoxVisible = true, Checked = true
            };
            ElementStyle style = new ElementStyle();

            style.TextAlignment = eStyleTextAlignment.Far;
            node.Cells.Add(new Cell(part.Type.ToString(), style));
            node.Cells.Add(new Cell(part.NewFileLength.ToString("n0"), style));
            node.Cells.Add(new Cell(part.NewChecksum.ToString("x8"), style));
            node.Cells.Add(new Cell(part.OldChecksum?.ToString("x8"), style));
            if (part.Type == 1)
            {
                string text = string.Format("{0}|{1}|{2}|{3}", part.Action0, part.Action1, part.Action2, part.DependencyFiles.Count);
                node.Cells.Add(new Cell(text, style));
            }
            node.Tag = part;
            return(node);
        }