From 12dc22de1865c1fa139f59c7bcdc4fb0e1c209f2 Mon Sep 17 00:00:00 2001 From: adelikat Date: Sun, 13 Apr 2014 12:52:36 +0000 Subject: [PATCH] PCE CDL - center parent, add to toolbox --- .../tools/PCE/PCECDL.Designer.cs | 1 + .../tools/ToolBox.Designer.cs | 17 +++++++++++++++-- BizHawk.Client.EmuHawk/tools/ToolBox.cs | 11 +++++++++-- 3 files changed, 25 insertions(+), 4 deletions(-) diff --git a/BizHawk.Client.EmuHawk/tools/PCE/PCECDL.Designer.cs b/BizHawk.Client.EmuHawk/tools/PCE/PCECDL.Designer.cs index 8f8b05d0c3..7d4e93faab 100644 --- a/BizHawk.Client.EmuHawk/tools/PCE/PCECDL.Designer.cs +++ b/BizHawk.Client.EmuHawk/tools/PCE/PCECDL.Designer.cs @@ -259,6 +259,7 @@ this.MainMenuStrip = this.menuStrip1; this.MinimumSize = new System.Drawing.Size(150, 130); this.Name = "PCECDL"; + this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent; this.Text = "Code Data Logger"; this.Load += new System.EventHandler(this.PCECDL_Load); this.DragDrop += new System.Windows.Forms.DragEventHandler(this.PCECDL_DragDrop); diff --git a/BizHawk.Client.EmuHawk/tools/ToolBox.Designer.cs b/BizHawk.Client.EmuHawk/tools/ToolBox.Designer.cs index 9e14524946..2105e27185 100644 --- a/BizHawk.Client.EmuHawk/tools/ToolBox.Designer.cs +++ b/BizHawk.Client.EmuHawk/tools/ToolBox.Designer.cs @@ -50,6 +50,7 @@ this.PceBgViewerToolbarItem = new System.Windows.Forms.ToolStripButton(); this.GbaGpuViewerToolBarItem = new System.Windows.Forms.ToolStripButton(); this.GenesisGameGenieToolBarItem = new System.Windows.Forms.ToolStripButton(); + this.PceCdlToolbarItem = new System.Windows.Forms.ToolStripButton(); this.ToolBoxStrip.SuspendLayout(); this.SuspendLayout(); // @@ -81,6 +82,7 @@ this.GGGameGenieToolbarItem, this.GbGpuViewerToolBarItem, this.GBGameGenieToolbarItem, + this.PceCdlToolbarItem, this.PceBgViewerToolbarItem, this.GbaGpuViewerToolBarItem, this.GenesisGameGenieToolBarItem}); @@ -88,7 +90,7 @@ this.ToolBoxStrip.Location = new System.Drawing.Point(2, 2); this.ToolBoxStrip.Name = "ToolBoxStrip"; this.ToolBoxStrip.Padding = new System.Windows.Forms.Padding(0); - this.ToolBoxStrip.Size = new System.Drawing.Size(137, 141); + this.ToolBoxStrip.Size = new System.Drawing.Size(137, 175); this.ToolBoxStrip.Stretch = true; this.ToolBoxStrip.TabIndex = 0; this.ToolBoxStrip.TabStop = true; @@ -285,11 +287,21 @@ this.GenesisGameGenieToolBarItem.ToolTipText = "Genesis Game Genie Encoder/Decoder"; this.GenesisGameGenieToolBarItem.Click += new System.EventHandler(this.GenesisGameGenieToolBarItem_Click); // + // PceCdlToolbarItem + // + this.PceCdlToolbarItem.Image = global::BizHawk.Client.EmuHawk.Properties.Resources.pcejin1; + this.PceCdlToolbarItem.ImageTransparentColor = System.Drawing.Color.Magenta; + this.PceCdlToolbarItem.Name = "PceCdlToolbarItem"; + this.PceCdlToolbarItem.Size = new System.Drawing.Size(45, 20); + this.PceCdlToolbarItem.Text = "Cdl"; + this.PceCdlToolbarItem.ToolTipText = "PC Engine Code Data Logger"; + this.PceCdlToolbarItem.Click += new System.EventHandler(this.PceCdlToolbarItem_Click); + // // ToolBox // this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(140, 145); + this.ClientSize = new System.Drawing.Size(140, 179); this.Controls.Add(this.ToolBoxStrip); this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon"))); this.MaximumSize = new System.Drawing.Size(270, 600); @@ -326,6 +338,7 @@ private System.Windows.Forms.ToolStripButton GbGpuViewerToolBarItem; private System.Windows.Forms.ToolStripButton GbaGpuViewerToolBarItem; private System.Windows.Forms.ToolStripButton GenesisGameGenieToolBarItem; + private System.Windows.Forms.ToolStripButton PceCdlToolbarItem; } } \ No newline at end of file diff --git a/BizHawk.Client.EmuHawk/tools/ToolBox.cs b/BizHawk.Client.EmuHawk/tools/ToolBox.cs index 0805498417..921d3544b5 100644 --- a/BizHawk.Client.EmuHawk/tools/ToolBox.cs +++ b/BizHawk.Client.EmuHawk/tools/ToolBox.cs @@ -61,7 +61,9 @@ namespace BizHawk.Client.EmuHawk GGGameGenieToolbarItem.Visible = Global.Game.System == "GG"; - PceBgViewerToolbarItem.Visible = Global.Emulator is PCEngine; + PceCdlToolbarItem.Visible = + PceBgViewerToolbarItem.Visible = + Global.Emulator is PCEngine; GBGameGenieToolbarItem.Visible = GbGpuViewerToolBarItem.Visible = @@ -80,7 +82,7 @@ namespace BizHawk.Client.EmuHawk } } - NesDebuggerToolbarItem.Visible = !VersionInfo.INTERIM; + NesDebuggerToolbarItem.Visible = !VersionInfo.INTERIM && Global.Emulator.SystemId == "NES"; } private void SetSize() @@ -198,6 +200,11 @@ namespace BizHawk.Client.EmuHawk GlobalWin.Tools.Load(); } + private void PceCdlToolbarItem_Click(object sender, EventArgs e) + { + GlobalWin.Tools.Load(); + } + private void PceBgViewerToolbarItem_Click(object sender, EventArgs e) { GlobalWin.Tools.Load();