コード例 #1
0
        public MainWindow()
        {
            InitializeComponent();

            display = new DisplayVM();
            outPan = new OutputPanelVM();

            outManager = new OutputManager();
            fileVM_ = new FileModel(outManager);
            sManager = new SimManager(outManager);
            outManager.link(display, fileVM_, outPan, sManager);

            elemDef = new ElemDefVM(sManager, outManager);
            envDef = new EnvironmentDefVM(sManager);
            simSett = new SimSettingsVM(sManager);

            this.ElemDefTools.DataContext = elemDef;
            this.EnvDefTools.DataContext = envDef;
            this.SimSetTools.DataContext = simSett;
            this.SceneDisplay.DataContext = display;
            this.OutputPanel.DataContext = outPan;

            Loaded += MyWindow_Loaded;
            SizeChanged += OnResize;
            dispTimer.Tick += onDispStep;
        }
コード例 #2
0
        public void link(DisplayVM dispVM, FileModel FVM, OutputPanelVM outPanel, SimManager sM)
        {
            disVM = dispVM;
            outPan = outPanel;
            fileVm_ = FVM;
            simMan = sM;

            RTTimer.Elapsed += IncrementRT;
            RTTimer.AutoReset = true;
        }