Inheritance: System.Windows.Controls.TreeView
        public RecurseDirectoriesIncrementally()
        {
            Title = "Recurse Directories Incrementally";

            // Create Grid as content of window.

            // Создайте Grid как содержимое окна.
            Grid grid = new Grid();

            Content = grid;

            // Define ColumnDefinition objects.

            // Добавляет три колонки
            ColumnDefinition coldef = new ColumnDefinition();

            coldef.Width = new GridLength(50, GridUnitType.Star);
            grid.ColumnDefinitions.Add(coldef);

            coldef       = new ColumnDefinition();
            coldef.Width = GridLength.Auto;
            grid.ColumnDefinitions.Add(coldef);

            coldef       = new ColumnDefinition();
            coldef.Width = new GridLength(50, GridUnitType.Star);
            grid.ColumnDefinitions.Add(coldef);

            // Put DirectoryTreeView at left.
            // Поместите DirectoryTreeView слева.
            // Вызывает конструктор класса DirectoryTreeView и создает объект tree этого класса
            // Переходим к класс DirectoryTreeView

            DirectoryTreeView tree = new DirectoryTreeView();

            //Делегат
            tree.SelectedItemChanged += TreeViewOnSelectedItemChanged;

            grid.Children.Add(tree);
            Grid.SetColumn(tree, 0);

            // Put GridSplitter in center.
            // Поместите GridSplitter в центр.
            GridSplitter split = new GridSplitter();

            split.Width          = 6;
            split.ResizeBehavior = GridResizeBehavior.PreviousAndNext;
            grid.Children.Add(split);
            Grid.SetColumn(split, 1);

            // Put scrolled StackPanel at right.
            // Поместите прокрученный StackPanel справа.
            ScrollViewer scroll = new ScrollViewer();

            grid.Children.Add(scroll);
            Grid.SetColumn(scroll, 2);

            stack          = new StackPanel();
            scroll.Content = stack;
        }
        public RecurseDirectoriesIncrementally()
        {
            Title = "Recurse Directories Incrementally";

            // Create Grid as content of window.
            Grid grid = new Grid();

            Content = grid;

            // Define ColumnDefinition objects.
            ColumnDefinition coldef = new ColumnDefinition();

            coldef.Width = new GridLength(50, GridUnitType.Star);
            grid.ColumnDefinitions.Add(coldef);

            coldef       = new ColumnDefinition();
            coldef.Width = GridLength.Auto;
            grid.ColumnDefinitions.Add(coldef);

            coldef       = new ColumnDefinition();
            coldef.Width = new GridLength(50, GridUnitType.Star);
            grid.ColumnDefinitions.Add(coldef);

            // Put DirectoryTreeView at left.
            DirectoryTreeView tree = new DirectoryTreeView();

            tree.SelectedItemChanged += TreeViewOnSelectedItemChanged;
            grid.Children.Add(tree);
            Grid.SetColumn(tree, 0);

            // Put GridSplitter in center.
            GridSplitter split = new GridSplitter();

            split.Width          = 6;
            split.ResizeBehavior = GridResizeBehavior.PreviousAndNext;
            grid.Children.Add(split);
            Grid.SetColumn(split, 1);

            // Put scrolled StackPanel at right.
            ScrollViewer scroll = new ScrollViewer();

            grid.Children.Add(scroll);
            Grid.SetColumn(scroll, 2);

            stack          = new StackPanel();
            scroll.Content = stack;
        }
        public RecurseDirectoriesIncrementally()
        {
            Title = "Recurse Directories Incrementally";

            // Create Grid as content of window.
            Grid grid = new Grid();
            Content = grid;

            // Define ColumnDefinition objects.
            ColumnDefinition coldef = new ColumnDefinition();
            coldef.Width = new GridLength(50, GridUnitType.Star);
            grid.ColumnDefinitions.Add(coldef);

            coldef = new ColumnDefinition();
            coldef.Width = GridLength.Auto;
            grid.ColumnDefinitions.Add(coldef);

            coldef = new ColumnDefinition();
            coldef.Width = new GridLength(50, GridUnitType.Star);
            grid.ColumnDefinitions.Add(coldef);

            // Put DirectoryTreeView at left.
            DirectoryTreeView tree = new DirectoryTreeView();
            tree.SelectedItemChanged += TreeViewOnSelectedItemChanged;
            grid.Children.Add(tree);
            Grid.SetColumn(tree, 0);

            // Put GridSplitter in center.
            GridSplitter split = new GridSplitter();
            split.Width = 6;
            split.ResizeBehavior = GridResizeBehavior.PreviousAndNext;
            grid.Children.Add(split);
            Grid.SetColumn(split, 1);

            // Put scrolled StackPanel at right.
            ScrollViewer scroll = new ScrollViewer();
            grid.Children.Add(scroll);
            Grid.SetColumn(scroll, 2);

            stack = new StackPanel();
            scroll.Content = stack;
        }