Ejemplo n.º 1
0
        private void deleteToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (selectedNode != null)
            {
                treeViewTools.SelectedNode = selectedNode;

                game sourceGame = null;
                rom  sourceRom  = null;

                if (selectedNode.Tag is rom)
                {
                    sourceRom  = (rom)selectedNode.Tag;
                    sourceGame = (game)selectedNode.Parent.Tag;
                }
                else
                {
                    sourceGame = (game)selectedNode.Tag;
                }

                this.datafileObject = AuditingUtil.DeleteItemFromDatafile(this.datafileObject, sourceGame, sourceRom);
                this.loadDataFileIntoTree(this.datafileObject);
            }
            else
            {
                MessageBox.Show(ConfigurationManager.AppSettings["Form_DatafileEditor_ErrorDatafileSelectedNode"],
                                ConfigurationManager.AppSettings["Form_DatafileEditor_ErrorDatafileSelectedNodeTitle"]);
            }
        }
Ejemplo n.º 2
0
Archivo: Cpu.cs Proyecto: izik1/JAGBE
 /// <summary>
 /// Initializes a new instance of the <see cref="Cpu"/> class.
 /// </summary>
 /// <param name="bootRom">The boot rom.</param>
 /// <param name="rom">The rom.</param>
 /// <param name="inputHandler">The input handler.</param>
 public Cpu(byte[] bootRom, byte[] rom, IInputHandler inputHandler) => Reset(rom, bootRom, inputHandler);