public ItemSelectorControl( ITreeItem itemEditor )
        {
            ItemEditor = itemEditor ;

            InitializeComponent( ) ;

            _levelExplorer = new LevelExplorerControl
                {
                    Dock = DockStyle.Fill,
                    Parent = this,
                    CheckBoxes= false,
                    Visible = true,
                    ShowToolStrip = false,
                    HideContextMenus=true,
                    InteractsWithModel=false
                } ;

            _levelExplorer.ItemSelected += ( s, e ) =>
                                           	{
                                           		if( e.Item is ItemEditor )
                                           		{
                                           			ItemEditor = e.Item as ItemEditor ;
                                           		}
                                           	} ;

            Controls.Add( _levelExplorer );

            _levelExplorer.Refresh(  );
        }
예제 #2
0
        public ItemSelectorControl(ITreeItem itemEditor)
        {
            ItemEditor = itemEditor;

            InitializeComponent( );

            _levelExplorer = new LevelExplorerControl
            {
                Dock               = DockStyle.Fill,
                Parent             = this,
                CheckBoxes         = false,
                Visible            = true,
                ShowToolStrip      = false,
                HideContextMenus   = true,
                InteractsWithModel = false
            };

            _levelExplorer.ItemSelected += (s, e) =>
            {
                if (e.Item is ItemEditor)
                {
                    ItemEditor = e.Item as ItemEditor;
                }
            };

            Controls.Add(_levelExplorer);

            _levelExplorer.Refresh(  );
        }