Beispiel #1
0
 /// <summary>
 /// Initialize instance of class
 /// </summary>
 public PMView(SimView view, ref List <MicroOperation> List_MicroOps)
 {
     this.view = view;
     InitializeComponent();
     this.List_MicroOps = List_MicroOps;
     LoadMicroOperations();
     setAllStrings();
 }
Beispiel #2
0
 /// <summary>
 /// Initialize instance of class
 /// </summary>
 public MemView(SimView view, ref List <MemoryRecord> List_Memory)
 {
     this.view        = view;
     this.List_Memory = List_Memory;
     InitializeComponent();
     dataGridView_Basic.Rows.Add(3);
     LoadMemory();
 }
Beispiel #3
0
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            ISimModel      model      = new SimModel();
            ISimView       view       = new SimView();
            ISimController controller = new SimController(model, view);

            //start a new thread with controller.simulate()
            //throw new NotImplementedException();
            Application.Run(view.mainWindow);
            // NEED TO START NEW THREAD FOR SIMULATION
        }
Beispiel #4
0
 internal DevConsole(SimView view)
 {
     this.viewRef = view;
     InitializeComponent();
     AcceptButton = buttonStart;
 }
        public void InitializeObjects()
        {
            this.helpLastSimState = this.sim.IsRunning;

            this.menuBg = new RectangleShape {
                FillColor = new Color(0, 0, 0, 128),
                Position = new Vector2f(0, 0)
            };

            this.helpText = new Text("[F1] - Help", Resources.DefaultFont, 12) {
                Color = Color.White,
                Position = new Vector2f(5, 2)
            };

            this.fpsText = new Text("FPS: ?", Resources.DefaultFont, 12) {
                Color = Color.White
            };

            this.simStateText = new Text("", Resources.DefaultFont, 12) {
                Color = Color.White
            };

            this.helpOverlay = new HelpOverlay(this);
            this.helpOverlay.InitializeObjects();

            this.simView = new SimView(this);
            this.simView.InitializeObjects();

            this.simTex = new RenderTexture(
                (uint) this.simView.Width,
                (uint) this.simView.Height);
        }