From 0397ea1ff475307b2d420f0e568b72994d54cb74 Mon Sep 17 00:00:00 2001 From: adelikat Date: Sun, 27 Jul 2014 15:22:30 +0000 Subject: [PATCH] Remove the CustomControls/Util file and move all the classes into the Form Extensions file, since they were all extension methods for window form objects --- .../BizHawk.Client.EmuHawk.csproj | 1 - BizHawk.Client.EmuHawk/CustomControls/Util.cs | 171 ------------------ .../Extensions/ControlExtensions.cs | 165 ++++++++++++++++- BizHawk.Client.EmuHawk/MainForm.Events.cs | 1 + BizHawk.Client.EmuHawk/MainForm.cs | 2 + .../config/FirmwaresConfig.cs | 1 + .../config/FirmwaresConfigInfo.cs | 2 + BizHawk.Client.EmuHawk/config/GB/BmpView.cs | 1 + .../config/N64/N64VideoPluginconfig.cs | 2 +- .../config/N64/NewN64PluginSettings.cs | 2 +- BizHawk.Client.EmuHawk/movie/PlayMovie.cs | 1 + BizHawk.Client.EmuHawk/movie/RecordMovie.cs | 2 + BizHawk.Client.EmuHawk/tools/BatchRun.cs | 2 + BizHawk.Client.EmuHawk/tools/GB/GBGPUView.cs | 1 + .../tools/HexEditor/HexEditor.cs | 1 + .../tools/Lua/LuaConsole.cs | 4 +- .../tools/NES/NameTableViewer.cs | 1 + .../tools/NES/PaletteViewer.cs | 1 + .../tools/NES/PatternViewer.cs | 1 + .../tools/NES/SpriteViewer.cs | 1 + .../tools/TAStudio/TAStudio.cs | 4 +- BizHawk.Client.EmuHawk/tools/ToolHelpers.cs | 1 + BizHawk.Client.EmuHawk/tools/TraceLogger.cs | 1 + .../tools/Watch/RamSearch.cs | 2 + .../tools/Watch/RamWatch.cs | 1 + 25 files changed, 195 insertions(+), 177 deletions(-) delete mode 100644 BizHawk.Client.EmuHawk/CustomControls/Util.cs diff --git a/BizHawk.Client.EmuHawk/BizHawk.Client.EmuHawk.csproj b/BizHawk.Client.EmuHawk/BizHawk.Client.EmuHawk.csproj index 66a3055d42..dabafde2bb 100644 --- a/BizHawk.Client.EmuHawk/BizHawk.Client.EmuHawk.csproj +++ b/BizHawk.Client.EmuHawk/BizHawk.Client.EmuHawk.csproj @@ -479,7 +479,6 @@ Component - Component diff --git a/BizHawk.Client.EmuHawk/CustomControls/Util.cs b/BizHawk.Client.EmuHawk/CustomControls/Util.cs deleted file mode 100644 index c50d793ee0..0000000000 --- a/BizHawk.Client.EmuHawk/CustomControls/Util.cs +++ /dev/null @@ -1,171 +0,0 @@ -using System; -using System.ComponentModel; -using System.Runtime.InteropServices; -using System.Text; -using System.Windows.Forms; - -namespace BizHawk.Client.EmuHawk -{ - public static class Extensions - { - // extension method to make Control.Invoke easier to use - public static void Invoke(this Control control, Action action) - { - control.Invoke(action); - } - } - - public static class WinFormExtensions - { - /// - /// Handles EmuHawk specific issues before showing a modal dialog - /// - public static DialogResult ShowHawkDialog(this Form form) - { - GlobalWin.Sound.StopSound(); - var result = form.ShowDialog(); - GlobalWin.Sound.StartSound(); - return result; - } - - /// - /// Handles EmuHawk specific issues before showing a modal dialog - /// - public static DialogResult ShowHawkDialog(this CommonDialog form) - { - GlobalWin.Sound.StopSound(); - var result = form.ShowDialog(); - GlobalWin.Sound.StartSound(); - return result; - } - } - - public static class ListViewExtensions - { - [StructLayout(LayoutKind.Sequential)] - public struct HDITEM - { - public Mask mask; - public int cxy; - [MarshalAs(UnmanagedType.LPTStr)] - public string pszText; - public IntPtr hbm; - public int cchTextMax; - public Format fmt; - public IntPtr lParam; - // _WIN32_IE >= 0x0300 - public int iImage; - public int iOrder; - // _WIN32_IE >= 0x0500 - public uint type; - public IntPtr pvFilter; - // _WIN32_WINNT >= 0x0600 - public uint state; - - [Flags] - public enum Mask - { - Format = 0x4, // HDI_FORMAT - }; - - [Flags] - public enum Format - { - SortDown = 0x200, // HDF_SORTDOWN - SortUp = 0x400, // HDF_SORTUP - }; - }; - - public const int LVM_FIRST = 0x1000; - public const int LVM_GETHEADER = LVM_FIRST + 31; - - public const int HDM_FIRST = 0x1200; - public const int HDM_GETITEM = HDM_FIRST + 11; - public const int HDM_SETITEM = HDM_FIRST + 12; - - [DllImport("user32.dll", CharSet = CharSet.Auto, SetLastError = true)] - static extern IntPtr SendMessage(IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam); - - [DllImport("user32.dll", CharSet = CharSet.Auto, SetLastError = true)] - static extern IntPtr SendMessage(IntPtr hWnd, UInt32 msg, IntPtr wParam, ref HDITEM lParam); - - /// - /// Dumps the contents of the ListView into a tab separated list of lines - /// - public static string CopyItemsAsText(this ListView listViewControl) - { - var indexes = listViewControl.SelectedIndices; - if (indexes.Count <= 0) - { - return String.Empty; - } - - var sb = new StringBuilder(); - - // walk over each selected item and subitem within it to generate a string from it - foreach (int index in indexes) - { - foreach (ListViewItem.ListViewSubItem item in listViewControl.Items[index].SubItems) - { - if (!String.IsNullOrWhiteSpace(item.Text)) - { - sb.Append(item.Text).Append('\t'); - } - } - - // remove the last tab - sb.Remove(sb.Length - 1, 1); - - sb.Append("\r\n"); - } - - // remove last newline - sb.Length -= 2; - - - return sb.ToString(); - } - - public static void SetSortIcon(this ListView listViewControl, int columnIndex, SortOrder order) - { - IntPtr columnHeader = SendMessage(listViewControl.Handle, LVM_GETHEADER, IntPtr.Zero, IntPtr.Zero); - for (int columnNumber = 0; columnNumber <= listViewControl.Columns.Count - 1; columnNumber++) - { - var columnPtr = new IntPtr(columnNumber); - var item = new HDITEM - { - mask = HDITEM.Mask.Format - }; - - if (SendMessage(columnHeader, HDM_GETITEM, columnPtr, ref item) == IntPtr.Zero) - { - throw new Win32Exception(); - } - - if (order != SortOrder.None && columnNumber == columnIndex) - { - switch (order) - { - case SortOrder.Ascending: - item.fmt &= ~HDITEM.Format.SortDown; - item.fmt |= HDITEM.Format.SortUp; - break; - case SortOrder.Descending: - item.fmt &= ~HDITEM.Format.SortUp; - item.fmt |= HDITEM.Format.SortDown; - break; - } - } - else - { - item.fmt &= ~HDITEM.Format.SortDown & ~HDITEM.Format.SortUp; - } - - if (SendMessage(columnHeader, HDM_SETITEM, columnPtr, ref item) == IntPtr.Zero) - { - throw new Win32Exception(); - } - } - } - } -} \ No newline at end of file diff --git a/BizHawk.Client.EmuHawk/Extensions/ControlExtensions.cs b/BizHawk.Client.EmuHawk/Extensions/ControlExtensions.cs index 132b558508..8cb64020e3 100644 --- a/BizHawk.Client.EmuHawk/Extensions/ControlExtensions.cs +++ b/BizHawk.Client.EmuHawk/Extensions/ControlExtensions.cs @@ -1,13 +1,16 @@ using System; using System.Collections.Generic; +using System.ComponentModel; using System.Linq; +using System.Runtime.InteropServices; using System.Text; using System.Windows.Forms; using BizHawk.Common; using BizHawk.Common.ReflectionExtensions; -namespace BizHawk.Client.EmuHawk.ControlExtensions + +namespace BizHawk.Client.EmuHawk.WinFormExtensions { public static class ControlExtensions { @@ -25,5 +28,165 @@ namespace BizHawk.Client.EmuHawk.ControlExtensions .ToArray()); box.SelectedItem = enumVal.GetDescription(); } + + // extension method to make Control.Invoke easier to use + public static void Invoke(this Control control, Action action) + { + control.Invoke(action); + } + } + + public static class FormExtensions + { + /// + /// Handles EmuHawk specific issues before showing a modal dialog + /// + public static DialogResult ShowHawkDialog(this Form form) + { + GlobalWin.Sound.StopSound(); + var result = form.ShowDialog(); + GlobalWin.Sound.StartSound(); + return result; + } + + /// + /// Handles EmuHawk specific issues before showing a modal dialog + /// + public static DialogResult ShowHawkDialog(this CommonDialog form) + { + GlobalWin.Sound.StopSound(); + var result = form.ShowDialog(); + GlobalWin.Sound.StartSound(); + return result; + } + } + + public static class ListViewExtensions + { + [StructLayout(LayoutKind.Sequential)] + public struct HDITEM + { + public Mask mask; + public int cxy; + [MarshalAs(UnmanagedType.LPTStr)] + public string pszText; + public IntPtr hbm; + public int cchTextMax; + public Format fmt; + public IntPtr lParam; + // _WIN32_IE >= 0x0300 + public int iImage; + public int iOrder; + // _WIN32_IE >= 0x0500 + public uint type; + public IntPtr pvFilter; + // _WIN32_WINNT >= 0x0600 + public uint state; + + [Flags] + public enum Mask + { + Format = 0x4, // HDI_FORMAT + }; + + [Flags] + public enum Format + { + SortDown = 0x200, // HDF_SORTDOWN + SortUp = 0x400, // HDF_SORTUP + }; + }; + + public const int LVM_FIRST = 0x1000; + public const int LVM_GETHEADER = LVM_FIRST + 31; + + public const int HDM_FIRST = 0x1200; + public const int HDM_GETITEM = HDM_FIRST + 11; + public const int HDM_SETITEM = HDM_FIRST + 12; + + [DllImport("user32.dll", CharSet = CharSet.Auto, SetLastError = true)] + static extern IntPtr SendMessage(IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam); + + [DllImport("user32.dll", CharSet = CharSet.Auto, SetLastError = true)] + static extern IntPtr SendMessage(IntPtr hWnd, UInt32 msg, IntPtr wParam, ref HDITEM lParam); + + /// + /// Dumps the contents of the ListView into a tab separated list of lines + /// + public static string CopyItemsAsText(this ListView listViewControl) + { + var indexes = listViewControl.SelectedIndices; + if (indexes.Count <= 0) + { + return String.Empty; + } + + var sb = new StringBuilder(); + + // walk over each selected item and subitem within it to generate a string from it + foreach (int index in indexes) + { + foreach (ListViewItem.ListViewSubItem item in listViewControl.Items[index].SubItems) + { + if (!String.IsNullOrWhiteSpace(item.Text)) + { + sb.Append(item.Text).Append('\t'); + } + } + + // remove the last tab + sb.Remove(sb.Length - 1, 1); + + sb.Append("\r\n"); + } + + // remove last newline + sb.Length -= 2; + + + return sb.ToString(); + } + + public static void SetSortIcon(this ListView listViewControl, int columnIndex, SortOrder order) + { + IntPtr columnHeader = SendMessage(listViewControl.Handle, LVM_GETHEADER, IntPtr.Zero, IntPtr.Zero); + for (int columnNumber = 0; columnNumber <= listViewControl.Columns.Count - 1; columnNumber++) + { + var columnPtr = new IntPtr(columnNumber); + var item = new HDITEM + { + mask = HDITEM.Mask.Format + }; + + if (SendMessage(columnHeader, HDM_GETITEM, columnPtr, ref item) == IntPtr.Zero) + { + throw new Win32Exception(); + } + + if (order != SortOrder.None && columnNumber == columnIndex) + { + switch (order) + { + case SortOrder.Ascending: + item.fmt &= ~HDITEM.Format.SortDown; + item.fmt |= HDITEM.Format.SortUp; + break; + case SortOrder.Descending: + item.fmt &= ~HDITEM.Format.SortUp; + item.fmt |= HDITEM.Format.SortDown; + break; + } + } + else + { + item.fmt &= ~HDITEM.Format.SortDown & ~HDITEM.Format.SortUp; + } + + if (SendMessage(columnHeader, HDM_SETITEM, columnPtr, ref item) == IntPtr.Zero) + { + throw new Win32Exception(); + } + } + } } } diff --git a/BizHawk.Client.EmuHawk/MainForm.Events.cs b/BizHawk.Client.EmuHawk/MainForm.Events.cs index 84472e2e95..f582b68b7e 100644 --- a/BizHawk.Client.EmuHawk/MainForm.Events.cs +++ b/BizHawk.Client.EmuHawk/MainForm.Events.cs @@ -17,6 +17,7 @@ using BizHawk.Emulation.Cores.Consoles.Nintendo.QuickNES; using BizHawk.Client.Common; using BizHawk.Client.EmuHawk.config.NES; using BizHawk.Client.EmuHawk.CustomControls; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/MainForm.cs b/BizHawk.Client.EmuHawk/MainForm.cs index 00afedef3f..13b01b09e1 100644 --- a/BizHawk.Client.EmuHawk/MainForm.cs +++ b/BizHawk.Client.EmuHawk/MainForm.cs @@ -33,6 +33,8 @@ using BizHawk.Emulation.Cores.Sony.PSP; using BizHawk.Emulation.DiscSystem; using BizHawk.Emulation.Cores.Nintendo.N64; +using BizHawk.Client.EmuHawk.WinFormExtensions; + namespace BizHawk.Client.EmuHawk { public partial class MainForm : Form diff --git a/BizHawk.Client.EmuHawk/config/FirmwaresConfig.cs b/BizHawk.Client.EmuHawk/config/FirmwaresConfig.cs index a01124ff97..f2ba915062 100644 --- a/BizHawk.Client.EmuHawk/config/FirmwaresConfig.cs +++ b/BizHawk.Client.EmuHawk/config/FirmwaresConfig.cs @@ -11,6 +11,7 @@ using System.Windows.Forms; using BizHawk.Client.Common; using BizHawk.Emulation.Common; +using BizHawk.Client.EmuHawk.WinFormExtensions; //notes: eventually, we intend to have a "firmware acquisition interface" exposed to the emulator cores. //it will be implemented by emuhawk, and use firmware keys to fetch the firmware content. diff --git a/BizHawk.Client.EmuHawk/config/FirmwaresConfigInfo.cs b/BizHawk.Client.EmuHawk/config/FirmwaresConfigInfo.cs index 95facc81e8..f88f68bb80 100644 --- a/BizHawk.Client.EmuHawk/config/FirmwaresConfigInfo.cs +++ b/BizHawk.Client.EmuHawk/config/FirmwaresConfigInfo.cs @@ -1,6 +1,8 @@ using System; using System.Windows.Forms; +using BizHawk.Client.EmuHawk.WinFormExtensions; + //todo - display details on the current resolution status //todo - check(mark) the one thats selected //todo - turn top info into textboxes i guess, labels suck diff --git a/BizHawk.Client.EmuHawk/config/GB/BmpView.cs b/BizHawk.Client.EmuHawk/config/GB/BmpView.cs index b5a445f499..1ce3ba20cd 100644 --- a/BizHawk.Client.EmuHawk/config/GB/BmpView.cs +++ b/BizHawk.Client.EmuHawk/config/GB/BmpView.cs @@ -7,6 +7,7 @@ using System.Drawing; using System.Windows.Forms; using BizHawk.Client.Common; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/config/N64/N64VideoPluginconfig.cs b/BizHawk.Client.EmuHawk/config/N64/N64VideoPluginconfig.cs index 3c85bab549..0d0c34921a 100644 --- a/BizHawk.Client.EmuHawk/config/N64/N64VideoPluginconfig.cs +++ b/BizHawk.Client.EmuHawk/config/N64/N64VideoPluginconfig.cs @@ -8,7 +8,7 @@ using BizHawk.Common.StringExtensions; using BizHawk.Common.ReflectionExtensions; using BizHawk.Emulation.Cores.Nintendo.N64; using BizHawk.Client.Common; -using BizHawk.Client.EmuHawk.ControlExtensions; +using BizHawk.Client.EmuHawk.WinFormExtensions; using System.IO; using System.Security.Cryptography; diff --git a/BizHawk.Client.EmuHawk/config/N64/NewN64PluginSettings.cs b/BizHawk.Client.EmuHawk/config/N64/NewN64PluginSettings.cs index a433b9c8b1..e7bd8bec8c 100644 --- a/BizHawk.Client.EmuHawk/config/N64/NewN64PluginSettings.cs +++ b/BizHawk.Client.EmuHawk/config/N64/NewN64PluginSettings.cs @@ -8,7 +8,7 @@ using BizHawk.Common.StringExtensions; using BizHawk.Common.ReflectionExtensions; using BizHawk.Emulation.Cores.Nintendo.N64; using BizHawk.Client.Common; -using BizHawk.Client.EmuHawk.ControlExtensions; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/movie/PlayMovie.cs b/BizHawk.Client.EmuHawk/movie/PlayMovie.cs index eb9f6ec555..3b72266977 100644 --- a/BizHawk.Client.EmuHawk/movie/PlayMovie.cs +++ b/BizHawk.Client.EmuHawk/movie/PlayMovie.cs @@ -9,6 +9,7 @@ using System.Windows.Forms; using BizHawk.Client.Common; using BizHawk.Common; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/movie/RecordMovie.cs b/BizHawk.Client.EmuHawk/movie/RecordMovie.cs index 0f7d35cbc3..8bcb2c35e2 100644 --- a/BizHawk.Client.EmuHawk/movie/RecordMovie.cs +++ b/BizHawk.Client.EmuHawk/movie/RecordMovie.cs @@ -7,6 +7,8 @@ using BizHawk.Emulation.Common; using BizHawk.Client.Common; using BizHawk.Client.Common.MovieConversionExtensions; +using BizHawk.Client.EmuHawk.WinFormExtensions; + namespace BizHawk.Client.EmuHawk { public partial class RecordMovie : Form diff --git a/BizHawk.Client.EmuHawk/tools/BatchRun.cs b/BizHawk.Client.EmuHawk/tools/BatchRun.cs index c4256a4156..4dbda880bf 100644 --- a/BizHawk.Client.EmuHawk/tools/BatchRun.cs +++ b/BizHawk.Client.EmuHawk/tools/BatchRun.cs @@ -9,6 +9,8 @@ using System.Windows.Forms; using System.Threading; using System.IO; +using BizHawk.Client.EmuHawk.WinFormExtensions; + namespace BizHawk.Client.EmuHawk { public partial class BatchRun : Form diff --git a/BizHawk.Client.EmuHawk/tools/GB/GBGPUView.cs b/BizHawk.Client.EmuHawk/tools/GB/GBGPUView.cs index cddd82f188..6932a5ba35 100644 --- a/BizHawk.Client.EmuHawk/tools/GB/GBGPUView.cs +++ b/BizHawk.Client.EmuHawk/tools/GB/GBGPUView.cs @@ -6,6 +6,7 @@ using System.Windows.Forms; using BizHawk.Common.NumberExtensions; using BizHawk.Client.Common; using BizHawk.Emulation.Cores.Nintendo.Gameboy; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/tools/HexEditor/HexEditor.cs b/BizHawk.Client.EmuHawk/tools/HexEditor/HexEditor.cs index bb2d0c5499..0332479084 100644 --- a/BizHawk.Client.EmuHawk/tools/HexEditor/HexEditor.cs +++ b/BizHawk.Client.EmuHawk/tools/HexEditor/HexEditor.cs @@ -14,6 +14,7 @@ using BizHawk.Common.StringExtensions; using BizHawk.Common.IOExtensions; using BizHawk.Emulation.Common; using BizHawk.Client.Common; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/tools/Lua/LuaConsole.cs b/BizHawk.Client.EmuHawk/tools/Lua/LuaConsole.cs index 44ea4d041e..812704e481 100644 --- a/BizHawk.Client.EmuHawk/tools/Lua/LuaConsole.cs +++ b/BizHawk.Client.EmuHawk/tools/Lua/LuaConsole.cs @@ -7,9 +7,11 @@ using System.Linq; using System.Text.RegularExpressions; using System.Windows.Forms; +using LuaInterface; + using BizHawk.Client.Common; using BizHawk.Emulation.Common; -using LuaInterface; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/tools/NES/NameTableViewer.cs b/BizHawk.Client.EmuHawk/tools/NES/NameTableViewer.cs index 4f993c7d46..90e4a9f09e 100644 --- a/BizHawk.Client.EmuHawk/tools/NES/NameTableViewer.cs +++ b/BizHawk.Client.EmuHawk/tools/NES/NameTableViewer.cs @@ -4,6 +4,7 @@ using System.IO; using System.Drawing.Imaging; using BizHawk.Client.Common; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/tools/NES/PaletteViewer.cs b/BizHawk.Client.EmuHawk/tools/NES/PaletteViewer.cs index fc7d2cec25..19a855ef6b 100644 --- a/BizHawk.Client.EmuHawk/tools/NES/PaletteViewer.cs +++ b/BizHawk.Client.EmuHawk/tools/NES/PaletteViewer.cs @@ -4,6 +4,7 @@ using System.IO; using System.Drawing.Imaging; using BizHawk.Client.Common; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/tools/NES/PatternViewer.cs b/BizHawk.Client.EmuHawk/tools/NES/PatternViewer.cs index fbc4ed09fb..e1521d4b13 100644 --- a/BizHawk.Client.EmuHawk/tools/NES/PatternViewer.cs +++ b/BizHawk.Client.EmuHawk/tools/NES/PatternViewer.cs @@ -4,6 +4,7 @@ using System.IO; using System.Drawing.Imaging; using BizHawk.Client.Common; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/tools/NES/SpriteViewer.cs b/BizHawk.Client.EmuHawk/tools/NES/SpriteViewer.cs index ec2e3dfb3f..3613b34cc1 100644 --- a/BizHawk.Client.EmuHawk/tools/NES/SpriteViewer.cs +++ b/BizHawk.Client.EmuHawk/tools/NES/SpriteViewer.cs @@ -4,6 +4,7 @@ using System.IO; using System.Drawing.Imaging; using BizHawk.Client.Common; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/tools/TAStudio/TAStudio.cs b/BizHawk.Client.EmuHawk/tools/TAStudio/TAStudio.cs index 8a3d2a76e5..6f06250fe5 100644 --- a/BizHawk.Client.EmuHawk/tools/TAStudio/TAStudio.cs +++ b/BizHawk.Client.EmuHawk/tools/TAStudio/TAStudio.cs @@ -3,11 +3,13 @@ using System.Collections.Generic; using System.Drawing; using System.IO; using System.Linq; +using System.Text; using System.Windows.Forms; using BizHawk.Client.Common; using BizHawk.Client.Common.MovieConversionExtensions; -using System.Text; + +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/tools/ToolHelpers.cs b/BizHawk.Client.EmuHawk/tools/ToolHelpers.cs index 934815d03e..b823146c2a 100644 --- a/BizHawk.Client.EmuHawk/tools/ToolHelpers.cs +++ b/BizHawk.Client.EmuHawk/tools/ToolHelpers.cs @@ -6,6 +6,7 @@ using System.Windows.Forms; using BizHawk.Client.Common; using BizHawk.Emulation.Common; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/tools/TraceLogger.cs b/BizHawk.Client.EmuHawk/tools/TraceLogger.cs index 57f24f40c1..4340f8a5ba 100644 --- a/BizHawk.Client.EmuHawk/tools/TraceLogger.cs +++ b/BizHawk.Client.EmuHawk/tools/TraceLogger.cs @@ -7,6 +7,7 @@ using System.Text; using System.Windows.Forms; using BizHawk.Client.Common; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk { diff --git a/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.cs b/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.cs index 79e148f1da..900d76354b 100644 --- a/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.cs +++ b/BizHawk.Client.EmuHawk/tools/Watch/RamSearch.cs @@ -13,6 +13,8 @@ using BizHawk.Common.StringExtensions; using BizHawk.Common.NumberExtensions; using BizHawk.Client.Common; +using BizHawk.Client.EmuHawk.WinFormExtensions; + namespace BizHawk.Client.EmuHawk { /// diff --git a/BizHawk.Client.EmuHawk/tools/Watch/RamWatch.cs b/BizHawk.Client.EmuHawk/tools/Watch/RamWatch.cs index 632edb0c7b..ff5d353c3d 100644 --- a/BizHawk.Client.EmuHawk/tools/Watch/RamWatch.cs +++ b/BizHawk.Client.EmuHawk/tools/Watch/RamWatch.cs @@ -8,6 +8,7 @@ using System.Text; using System.Windows.Forms; using BizHawk.Client.Common; +using BizHawk.Client.EmuHawk.WinFormExtensions; namespace BizHawk.Client.EmuHawk {