Exemple #1
0
        public override void AwakeFromNib()
        {
            base.AwakeFromNib();

            windowRef            = Window;
            windowRef.WillClose += (sender, e) => eventsHandler.OnVisibleChanged();
            windowRef.owner      = this;

            treeView.Delegate = new TreeViewDelegate()
            {
                owner = this
            };
            treeView.DataSource = treeDataSource;

            propertiesView.Init(this);
            propertiesView.Delegate = new PropertiesViewDelegate {
                owner = this, table = propertiesView
            };
            propertiesView.DataSource = propsDataSource;

            stateHistoryView.Delegate = new StateHistoryViewDelegate()
            {
                owner = this
            };
            stateHistoryView.DataSource   = stateHistoryDataSource;
            stateHistoryView.DoubleClick += (sender, e) => eventsHandler.OnChangeHistoryItemClicked(
                item: stateHistoryDataSource.data.ElementAtOrDefault((int)stateHistoryView.ClickedRow));
            ((StateHistoryTableView)stateHistoryView).owner = this;

            findCurrentPositionInStateHistoryButton.Image.Template = true;
        }
        public override void AwakeFromNib()
        {
            base.AwakeFromNib();

            windowRef            = Window;
            windowRef.WillClose += (sender, e) => viewModel.OnVisibleChanged(false);
            windowRef.owner      = this;

            treeViewController     = reactive.CreateOutlineViewController <IObjectsTreeNode> (treeView);
            stateHistoryController = reactive.CreateTableViewController <IStateHistoryItem> (stateHistoryView);

            propertiesView.Init(this);
            propertiesView.Delegate = new PropertiesViewDelegate {
                owner = this, table = propertiesView
            };
            propertiesView.DataSource = propsDataSource;

            stateHistoryView.DoubleClick += (sender, e) => viewModel.OnChangeHistoryItemDoubleClicked(
                viewModel.ChangeHistoryItems[(int)stateHistoryView.ClickedRow]);
            ((StateHistoryTableView)stateHistoryView).owner = this;

            findCurrentPositionInStateHistoryButton.Image.Template = true;
        }