Exemplo n.º 1
0
		public static FrameworkElement Create (FrameworkElement content, TreeController controller)
		{
			var panel = new StackPanel { Orientation = Orientation.Horizontal };
			var button = new TreeToggleButton { Controller = controller, Width = 16 };
			panel.Children.Add (button);
			panel.DataContextChanged += (sender, e) => button.Configure(panel.DataContext as ITreeGridItem);
			panel.Children.Add (content);
			return panel;
		}
Exemplo n.º 2
0
        public static FrameworkElement Create(FrameworkElement content, TreeController controller)
        {
            var panel = new StackPanel {
                Orientation = Orientation.Horizontal
            };
            var button = new TreeToggleButton {
                Controller = controller, Width = 16
            };

            panel.Children.Add(button);
            panel.DataContextChanged += (sender, e) => button.Configure(panel.DataContext as ITreeGridItem);
            panel.Children.Add(content);
            return(panel);
        }