public EmulatorManagementViewModel(IFolderBrowserDialogService folderBrowserDialogService, IEmulatorShell emulatorShell)
        {
            _folderBrowserDialogService = folderBrowserDialogService;
            _emulatorShell = emulatorShell;
            _emulatorShell.EmulationStopped += EmulationStopped;

            SelectRomDirectoryCommand = new RelayCommand <Visual>(SelectRom);
            StartEmulationCommand     = new RelayCommand(StartEmulation, () => !EmulationRunning);
            StopEmulationCommand      = new RelayCommand(StopEmulation, () => EmulationRunning);

            RomFilename      = "fishie.chip8";
            RomDirectoryPath = "C:\\chip8";
            CycleDelay       = 10;
        }
Exemple #2
0
 public EmulatorDisplayViewModel(IEmulatorShell emulatorShell)
 {
     _emulatorShell = emulatorShell;
     _emulatorShell.DrawRequired += OnDrawRequired;
 }
 public EmulatorRegistersViewModel(IRegisterBank registerBank, IEmulatorShell emulatorShell)
 {
     _registerBank             = registerBank;
     _emulatorShell            = emulatorShell;
     _emulatorShell.CycleTick += OnCycleTick;
 }