diff --git a/ExternalCoreProjects/Virtu/Cpu.cs b/ExternalCoreProjects/Virtu/Cpu.cs index 84d1d00454..fa529bdd1e 100644 --- a/ExternalCoreProjects/Virtu/Cpu.cs +++ b/ExternalCoreProjects/Virtu/Cpu.cs @@ -429,8 +429,6 @@ namespace Jellyfish.Virtu return CC; } - #region Core Operand Actions - private void GetAddressAbs() // abs { EA = _memory.Read(RPC) | (_memory.Read(RPC + 1) << 8); @@ -622,9 +620,6 @@ namespace Jellyfish.Virtu _memory.WriteZeroPage(EA, data); } - #endregion - - #region Core OpCode Actions private void ExecuteAdc65N02(int data, int cc) { if ((RP & Pd) == 0x0) @@ -1333,9 +1328,7 @@ namespace Jellyfish.Virtu RP = RP & ~(Pn | Pz) | DataPnz[RA]; CC += cc; } - #endregion - #region 6502 OpCode Actions private void Execute65X02And21() // and (zpg, x) { GetAddressZpgIndX(); @@ -2069,10 +2062,6 @@ namespace Jellyfish.Virtu ExecuteTya(2); } - #endregion - - #region 65N02 OpCode Actions - private void Execute65N02Adc61() // adc (zpg, x) { GetAddressZpgIndX(); @@ -2733,9 +2722,6 @@ namespace Jellyfish.Virtu ExecuteSbc65N02(ReadAbsX(), 4); } - #endregion - - #region 65C02 OpCode Actions private void Execute65C02Adc61() // adc (zpg, x) { GetAddressZpgIndX(); @@ -3419,8 +3405,6 @@ namespace Jellyfish.Virtu WriteAbs(ExecuteTsb(ReadAbs(), 6)); } - #endregion - private bool Is65C02 { get => _is65C02; diff --git a/ExternalCoreProjects/Virtu/Memory.cs b/ExternalCoreProjects/Virtu/Memory.cs index 48a1ebda66..7f73313332 100644 --- a/ExternalCoreProjects/Virtu/Memory.cs +++ b/ExternalCoreProjects/Virtu/Memory.cs @@ -280,8 +280,6 @@ namespace Jellyfish.Virtu MapRegionD0FF(); } - #region Core Read & Write - public int ReadOpcode(int address) { int region = PageRegion[address >> 8]; @@ -336,10 +334,6 @@ namespace Jellyfish.Virtu _zeroPage[address] = (byte)data; } - #endregion - - #region Read Actions - private int ReadIoRegionC0CF(int address) { switch (address & 0xFF00) @@ -794,10 +788,6 @@ namespace Jellyfish.Virtu return _romRegionE0FF[address - 0xE000]; } - #endregion - - #region Write Actions - private void WriteIoRegionC0C0(int address, byte data) { switch (address) @@ -1702,9 +1692,6 @@ namespace Jellyfish.Virtu { } - #endregion - - #region Softswitch Actions private void MapRegion0001() { if (!IsZeroPageAux) @@ -2070,8 +2057,6 @@ namespace Jellyfish.Virtu } } - #endregion - private static int SetBit7(int data, bool value) { return value ? data | 0x80 : data & 0x7F; diff --git a/ExternalCoreProjects/Virtu/Video.cs b/ExternalCoreProjects/Virtu/Video.cs index 4d12a1607b..0350f153c9 100644 --- a/ExternalCoreProjects/Virtu/Video.cs +++ b/ExternalCoreProjects/Virtu/Video.cs @@ -216,8 +216,6 @@ namespace Jellyfish.Virtu DirtyScreenText(); } - #region Draw Methods - private void DrawText40(int data, int x, int y) { int color = IsMonochrome ? ColorMono00 : ColorWhite00; @@ -737,9 +735,6 @@ namespace Jellyfish.Virtu } } - #endregion - - #region Flush Methods private void FlushRowMode0(int y) { int address = (_memory.IsVideoPage2 ? 0x0800 : 0x0400) + AddressOffset[y]; @@ -951,7 +946,6 @@ namespace Jellyfish.Virtu FlushRowMode2(y); // text80 } } - #endregion private void FlushRowEvent() { diff --git a/LuaInterface/LuaInterface/Lua.cs b/LuaInterface/LuaInterface/Lua.cs index 5e9bb9065c..ec5f10f74f 100644 --- a/LuaInterface/LuaInterface/Lua.cs +++ b/LuaInterface/LuaInterface/Lua.cs @@ -420,7 +420,6 @@ namespace NLua } } - #region Globals auto-complete private readonly List globals = new List(); private bool globalsSorted; @@ -460,7 +459,6 @@ namespace NLua // If the type is a class or an interface and recursion hasn't been running too long, list the members else if ((type.IsClass || type.IsInterface) && type != typeof(string) && recursionCounter < 2) { - #region Methods foreach (MethodInfo method in type.GetMethods(BindingFlags.Public | BindingFlags.Instance)) { if ( @@ -482,9 +480,7 @@ namespace NLua globals.Add(command); } } - #endregion - #region Fields foreach (FieldInfo field in type.GetFields(BindingFlags.Public | BindingFlags.Instance)) { if ( @@ -496,9 +492,7 @@ namespace NLua registerGlobal(path + "." + field.Name, field.FieldType, recursionCounter + 1); } } - #endregion - #region Properties foreach (PropertyInfo property in type.GetProperties(BindingFlags.Public | BindingFlags.Instance)) { if ( @@ -512,7 +506,6 @@ namespace NLua registerGlobal(path + "." + property.Name, property.PropertyType, recursionCounter + 1); } } - #endregion } // Otherwise simply add the element to the list else globals.Add(path); @@ -520,7 +513,6 @@ namespace NLua // List will need to be sorted on next access globalsSorted = false; } - #endregion @@ -726,8 +718,6 @@ namespace NLua * or userdata */ - #region lua debug functions - /// /// lua hook calback delegate /// @@ -960,8 +950,6 @@ namespace NLua translator.push(luaState, value); } - #endregion - List scheduledDisposes = new List(); internal void ScheduleDispose(int reference) @@ -1089,8 +1077,6 @@ namespace NLua translator.pushFunction(luaState,function); } - #region IDisposable Members - public virtual void Dispose() { if (translator != null) @@ -1103,8 +1089,6 @@ namespace NLua System.GC.Collect(); System.GC.WaitForPendingFinalizers(); } - - #endregion } /// diff --git a/LuaInterface/LuaInterface/LuaRegistrationHelper.cs b/LuaInterface/LuaInterface/LuaRegistrationHelper.cs index 5939787d59..1d58eaa1b4 100644 --- a/LuaInterface/LuaInterface/LuaRegistrationHelper.cs +++ b/LuaInterface/LuaInterface/LuaRegistrationHelper.cs @@ -6,7 +6,6 @@ namespace NLua { public static class LuaRegistrationHelper { - #region Tagged instance methods /// /// Registers all public instance methods in an object tagged with as Lua global functions /// @@ -14,10 +13,8 @@ namespace NLua /// The object to get the methods from public static void TaggedInstanceMethods(Lua lua, object o) { - #region Sanity checks if (lua == null) throw new ArgumentNullException("lua"); if (o == null) throw new ArgumentNullException("o"); - #endregion foreach (MethodInfo method in o.GetType().GetMethods(BindingFlags.Instance | BindingFlags.Public)) { @@ -30,9 +27,7 @@ namespace NLua } } } - #endregion - #region Tagged static methods /// /// Registers all public static methods in a class tagged with as Lua global functions /// @@ -40,11 +35,9 @@ namespace NLua /// The class type to get the methods from public static void TaggedStaticMethods(Lua lua, Type type) { - #region Sanity checks if (lua == null) throw new ArgumentNullException("lua"); if (type == null) throw new ArgumentNullException("type"); if (!type.IsClass) throw new ArgumentException("The type must be a class!", "type"); - #endregion foreach (MethodInfo method in type.GetMethods(BindingFlags.Static | BindingFlags.Public)) { @@ -57,9 +50,7 @@ namespace NLua } } } - #endregion - #region Enumeration /// /// Registers an enumeration's values for usage as a Lua variable table /// @@ -68,9 +59,7 @@ namespace NLua [SuppressMessage("Microsoft.Design", "CA1004:GenericMethodsShouldProvideTypeParameter", Justification = "The type parameter is used to select an enum type")] public static void Enumeration(Lua lua) { - #region Sanity checks if (lua == null) throw new ArgumentNullException("lua"); - #endregion Type type = typeof(T); if (!type.IsEnum) throw new ArgumentException("The type must be an enumeration!"); @@ -85,6 +74,5 @@ namespace NLua lua[path] = values[i]; } } - #endregion } }