Hex Editor - ~2 fps speedup
This commit is contained in:
parent
e62f68f48e
commit
3cb79b0dc7
|
@ -71,7 +71,9 @@ namespace BizHawk.MultiClient
|
|||
public void UpdateValues()
|
||||
{
|
||||
if (!this.IsHandleCreated || this.IsDisposed) return;
|
||||
MemoryViewer.BlazingFast = true;
|
||||
MemoryViewer.Refresh();
|
||||
MemoryViewer.BlazingFast = false;
|
||||
}
|
||||
|
||||
public void Restart()
|
||||
|
|
|
@ -6,6 +6,7 @@ using System.Linq;
|
|||
using System.Text;
|
||||
using System.Globalization;
|
||||
|
||||
|
||||
namespace BizHawk.MultiClient
|
||||
{
|
||||
public class MemoryViewer : Panel
|
||||
|
@ -36,6 +37,8 @@ namespace BizHawk.MultiClient
|
|||
const int rowY = 16;
|
||||
const int rowYoffset = 20;
|
||||
|
||||
public bool BlazingFast = false;
|
||||
|
||||
public MemoryViewer()
|
||||
{
|
||||
SetStyle(ControlStyles.AllPaintingInWmPaint, true);
|
||||
|
@ -517,5 +520,47 @@ namespace BizHawk.MultiClient
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
protected override void WndProc(ref System.Windows.Forms.Message m)
|
||||
{
|
||||
switch (m.Msg)
|
||||
{
|
||||
case 0x0201: //WM_LBUTTONDOWN
|
||||
{
|
||||
this.Focus();
|
||||
return;
|
||||
}
|
||||
//case 0x0202://WM_LBUTTONUP
|
||||
//{
|
||||
// return;
|
||||
//}
|
||||
case 0x0203://WM_LBUTTONDBLCLK
|
||||
{
|
||||
return;
|
||||
}
|
||||
case 0x0204://WM_RBUTTONDOWN
|
||||
{
|
||||
return;
|
||||
}
|
||||
case 0x0205://WM_RBUTTONUP
|
||||
{
|
||||
return;
|
||||
}
|
||||
case 0x0206://WM_RBUTTONDBLCLK
|
||||
{
|
||||
return;
|
||||
}
|
||||
case 0x0014: //WM_ERASEBKGND
|
||||
if (BlazingFast)
|
||||
{
|
||||
m.Result = new IntPtr(1);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
base.WndProc(ref m);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue