/[RomCheater]/trunk/RomCheater/Docking/UI/UIMemoryViewer.cs
ViewVC logotype

Diff of /trunk/RomCheater/Docking/UI/UIMemoryViewer.cs

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

--- trunk/RomCheater/Docking/UI/UIMemoryViewer.cs	2012/06/03 14:50:09	245
+++ trunk/RomCheater/Docking/UI/UIMemoryViewer.cs	2012/06/03 15:15:51	246
@@ -1,4 +1,6 @@
-´╗┐using System;
+´╗┐#define DISABLE_GETFIRSTNONZEROBYTE_ONUPDATE_ACCEPTEDPROCESS // when defined will not call GetFirstNonZeroByte() when AcceptedProcess is updated and is not null
+#define DISABLE_GETFIRSTNONZERO_BYTE // when defined will make GetFirstNonZeroByte() an empty void method
+using System;
 using System.Collections.Generic;
 using System.ComponentModel;
 using System.Drawing;
@@ -51,6 +53,7 @@
 
         private void GetFirstNonZeroByte()
         {
+#if !DISABLE_GETFIRSTNONZERO_BYTE
             if (!DesignMode)
             {
                 GenericMemoryProvider provider = new GenericMemoryProvider((IAcceptsProcessAndConfig)this);
@@ -60,6 +63,7 @@
                 provider.CloseProvider();
                 GotoAddress(addr);
             }
+#endif
         }
 
         #region  IAcceptsProcess<Process> Members
@@ -72,8 +76,10 @@
                 _AcceptedProcess = value;
                 update_timer.Enabled = (value != null);
                 UpdateEnabled = update_timer.Enabled;
+#if !DISABLE_GETFIRSTNONZEROBYTE_ONUPDATE_ACCEPTEDPROCESS
                 if (value != null)
                     GetFirstNonZeroByte();
+#endif
             }
         }
         #endregion

 

  ViewVC Help
Powered by ViewVC 1.1.22