Skip to content

Commit 062cced

Browse files
committed
Fixed parameter names.
1 parent 075d0be commit 062cced

30 files changed

+368
-372
lines changed

ReClass.NET/CodeGenerator/CppCodeGenerator.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -101,23 +101,23 @@ private class Utf8CharacterNode : BaseNode
101101
public override int MemorySize => throw new NotImplementedException();
102102
public override void GetUserInterfaceInfo(out string name, out Image icon) => throw new NotImplementedException();
103103
public override Size Draw(DrawContext context, int x, int y) => throw new NotImplementedException();
104-
public override int CalculateDrawnHeight(DrawContext view) => throw new NotImplementedException();
104+
public override int CalculateDrawnHeight(DrawContext context) => throw new NotImplementedException();
105105
}
106106

107107
private class Utf16CharacterNode : BaseNode
108108
{
109109
public override int MemorySize => throw new NotImplementedException();
110110
public override void GetUserInterfaceInfo(out string name, out Image icon) => throw new NotImplementedException();
111111
public override Size Draw(DrawContext context, int x, int y) => throw new NotImplementedException();
112-
public override int CalculateDrawnHeight(DrawContext view) => throw new NotImplementedException();
112+
public override int CalculateDrawnHeight(DrawContext context) => throw new NotImplementedException();
113113
}
114114

115115
private class Utf32CharacterNode : BaseNode
116116
{
117117
public override int MemorySize => throw new NotImplementedException();
118118
public override void GetUserInterfaceInfo(out string name, out Image icon) => throw new NotImplementedException();
119119
public override Size Draw(DrawContext context, int x, int y) => throw new NotImplementedException();
120-
public override int CalculateDrawnHeight(DrawContext view) => throw new NotImplementedException();
120+
public override int CalculateDrawnHeight(DrawContext context) => throw new NotImplementedException();
121121
}
122122

123123
#endregion

ReClass.NET/DataExchange/ReClass/Legacy/BaseClassArrayNode.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ public override void GetUserInterfaceInfo(out string name, out Image icon)
1414
throw new NotImplementedException();
1515
}
1616

17-
public override int CalculateDrawnHeight(DrawContext view)
17+
public override int CalculateDrawnHeight(DrawContext context)
1818
{
1919
throw new NotImplementedException();
2020
}

ReClass.NET/DataExchange/ReClass/Legacy/ClassPointerNode.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ public override void GetUserInterfaceInfo(out string name, out Image icon)
1414
throw new NotImplementedException();
1515
}
1616

17-
public override int CalculateDrawnHeight(DrawContext view)
17+
public override int CalculateDrawnHeight(DrawContext context)
1818
{
1919
throw new NotImplementedException();
2020
}

ReClass.NET/DataExchange/ReClass/Legacy/CustomNode.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ public override void GetUserInterfaceInfo(out string name, out Image icon)
1515
throw new NotImplementedException();
1616
}
1717

18-
public override int CalculateDrawnHeight(DrawContext view)
18+
public override int CalculateDrawnHeight(DrawContext context)
1919
{
2020
throw new NotImplementedException();
2121
}

ReClass.NET/Nodes/ArrayNode.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,14 @@ public override Size Draw(DrawContext context, int x, int y)
2727
return Draw(context, x, y, "Array");
2828
}
2929

30-
protected override Size DrawChild(DrawContext view, int x, int y)
30+
protected override Size DrawChild(DrawContext context, int x, int y)
3131
{
32-
var v = view.Clone();
33-
v.Address = view.Address + Offset + InnerNode.MemorySize * CurrentIndex;
34-
v.Memory = view.Memory.Clone();
35-
v.Memory.Offset += Offset + InnerNode.MemorySize * CurrentIndex;
32+
var innerContext = context.Clone();
33+
innerContext.Address = context.Address + Offset + InnerNode.MemorySize * CurrentIndex;
34+
innerContext.Memory = context.Memory.Clone();
35+
innerContext.Memory.Offset += Offset + InnerNode.MemorySize * CurrentIndex;
3636

37-
return InnerNode.Draw(v, x, y);
37+
return InnerNode.Draw(innerContext, x, y);
3838
}
3939
}
4040
}

ReClass.NET/Nodes/BaseFunctionPtrNode.cs

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -22,68 +22,68 @@ public override string GetToolTipText(HotSpot spot)
2222
return string.Join("\n", Instructions.Select(i => i.Instruction));
2323
}
2424

25-
protected Size Draw(DrawContext view, int x, int y, string type, string name)
25+
protected Size Draw(DrawContext context, int x, int y, string type, string name)
2626
{
27-
Contract.Requires(view != null);
27+
Contract.Requires(context != null);
2828
Contract.Requires(type != null);
2929
Contract.Requires(name != null);
3030

3131
if (IsHidden && !IsWrapped)
3232
{
33-
return DrawHidden(view, x, y);
33+
return DrawHidden(context, x, y);
3434
}
3535

3636
var origX = x;
3737

38-
AddSelection(view, x, y, view.Font.Height);
38+
AddSelection(context, x, y, context.Font.Height);
3939

40-
x = AddIconPadding(view, x);
40+
x = AddIconPadding(context, x);
4141

42-
x = AddIcon(view, x, y, view.IconProvider.Function, HotSpot.NoneId, HotSpotType.None);
42+
x = AddIcon(context, x, y, context.IconProvider.Function, HotSpot.NoneId, HotSpotType.None);
4343

4444
var tx = x;
4545

46-
x = AddAddressOffset(view, x, y);
46+
x = AddAddressOffset(context, x, y);
4747

48-
x = AddText(view, x, y, view.Settings.TypeColor, HotSpot.NoneId, type) + view.Font.Width;
48+
x = AddText(context, x, y, context.Settings.TypeColor, HotSpot.NoneId, type) + context.Font.Width;
4949
if (!IsWrapped)
5050
{
51-
x = AddText(view, x, y, view.Settings.NameColor, HotSpot.NameId, name) + view.Font.Width;
51+
x = AddText(context, x, y, context.Settings.NameColor, HotSpot.NameId, name) + context.Font.Width;
5252
}
5353

54-
x = AddOpenCloseIcon(view, x, y) + view.Font.Width;
54+
x = AddOpenCloseIcon(context, x, y) + context.Font.Width;
5555

56-
x = AddComment(view, x, y);
56+
x = AddComment(context, x, y);
5757

58-
if (view.Settings.ShowCommentSymbol)
58+
if (context.Settings.ShowCommentSymbol)
5959
{
60-
var value = view.Memory.ReadIntPtr(Offset);
60+
var value = context.Memory.ReadIntPtr(Offset);
6161

62-
var module = view.Process.GetModuleToPointer(value);
62+
var module = context.Process.GetModuleToPointer(value);
6363
if (module != null)
6464
{
65-
var symbols = view.Process.Symbols.GetSymbolsForModule(module);
65+
var symbols = context.Process.Symbols.GetSymbolsForModule(module);
6666
var symbol = symbols?.GetSymbolString(value, module);
6767
if (!string.IsNullOrEmpty(symbol))
6868
{
69-
x = AddText(view, x, y, view.Settings.OffsetColor, HotSpot.ReadOnlyId, symbol);
69+
x = AddText(context, x, y, context.Settings.OffsetColor, HotSpot.ReadOnlyId, symbol);
7070
}
7171
}
7272
}
7373

74-
DrawInvalidMemoryIndicatorIcon(view, y);
75-
AddContextDropDownIcon(view, y);
76-
AddDeleteIcon(view, y);
74+
DrawInvalidMemoryIndicatorIcon(context, y);
75+
AddContextDropDownIcon(context, y);
76+
AddDeleteIcon(context, y);
7777

78-
var size = new Size(x - origX, view.Font.Height);
78+
var size = new Size(x - origX, context.Font.Height);
7979

80-
if (LevelsOpen[view.Level])
80+
if (LevelsOpen[context.Level])
8181
{
82-
var ptr = view.Memory.ReadIntPtr(Offset);
82+
var ptr = context.Memory.ReadIntPtr(Offset);
8383

84-
DisassembleRemoteCode(view.Process, ptr);
84+
DisassembleRemoteCode(context.Process, ptr);
8585

86-
var instructionSize = DrawInstructions(view, tx, y);
86+
var instructionSize = DrawInstructions(context, tx, y);
8787

8888
size.Width = Math.Max(size.Width, instructionSize.Width + tx - origX);
8989
size.Height += instructionSize.Height;
@@ -92,17 +92,17 @@ protected Size Draw(DrawContext view, int x, int y, string type, string name)
9292
return size;
9393
}
9494

95-
public override int CalculateDrawnHeight(DrawContext view)
95+
public override int CalculateDrawnHeight(DrawContext context)
9696
{
9797
if (IsHidden)
9898
{
9999
return HiddenHeight;
100100
}
101101

102-
var height = view.Font.Height;
103-
if (LevelsOpen[view.Level])
102+
var height = context.Font.Height;
103+
if (LevelsOpen[context.Level])
104104
{
105-
height += Instructions.Count * view.Font.Height;
105+
height += Instructions.Count * context.Font.Height;
106106
}
107107
return height;
108108
}

ReClass.NET/Nodes/BaseHexNode.cs

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -32,75 +32,75 @@ protected BaseHexNode()
3232
buffer = new byte[MemorySize];
3333
}
3434

35-
protected Size Draw(DrawContext view, int x, int y, string text, int length)
35+
protected Size Draw(DrawContext context, int x, int y, string text, int length)
3636
{
37-
Contract.Requires(view != null);
37+
Contract.Requires(context != null);
3838

3939
if (IsHidden && !IsWrapped)
4040
{
41-
return DrawHidden(view, x, y);
41+
return DrawHidden(context, x, y);
4242
}
4343

4444
var origX = x;
4545

46-
AddSelection(view, x, y, view.Font.Height);
46+
AddSelection(context, x, y, context.Font.Height);
4747

48-
x = AddIconPadding(view, x);
49-
x = AddIconPadding(view, x);
48+
x = AddIconPadding(context, x);
49+
x = AddIconPadding(context, x);
5050

51-
x = AddAddressOffset(view, x, y);
51+
x = AddAddressOffset(context, x, y);
5252

5353
if (!string.IsNullOrEmpty(text))
5454
{
55-
x = AddText(view, x, y, view.Settings.TextColor, HotSpot.NoneId, text);
55+
x = AddText(context, x, y, context.Settings.TextColor, HotSpot.NoneId, text);
5656
}
5757

58-
view.Memory.ReadBytes(Offset, buffer);
58+
context.Memory.ReadBytes(Offset, buffer);
5959

60-
var color = view.Settings.HexColor;
61-
if (view.Settings.HighlightChangedValues)
60+
var color = context.Settings.HexColor;
61+
if (context.Settings.HighlightChangedValues)
6262
{
63-
var address = view.Address + Offset;
63+
var address = context.Address + Offset;
6464

65-
highlightTimer.RemoveWhere(kv => kv.Value.Value < view.CurrentTime);
65+
highlightTimer.RemoveWhere(kv => kv.Value.Value < context.CurrentTime);
6666

6767
if (highlightTimer.TryGetValue(address, out var until))
6868
{
69-
if (until.Value >= view.CurrentTime)
69+
if (until.Value >= context.CurrentTime)
7070
{
7171
color = GetRandomHighlightColor();
7272

73-
if (view.Memory.HasChanged(Offset, MemorySize))
73+
if (context.Memory.HasChanged(Offset, MemorySize))
7474
{
75-
until.Value = view.CurrentTime.Add(hightlightDuration);
75+
until.Value = context.CurrentTime.Add(hightlightDuration);
7676
}
7777
}
7878
}
79-
else if (view.Memory.HasChanged(Offset, MemorySize))
79+
else if (context.Memory.HasChanged(Offset, MemorySize))
8080
{
81-
highlightTimer.Add(address, view.CurrentTime.Add(hightlightDuration));
81+
highlightTimer.Add(address, context.CurrentTime.Add(hightlightDuration));
8282

8383
color = GetRandomHighlightColor();
8484
}
8585
}
8686

8787
for (var i = 0; i < length; ++i)
8888
{
89-
x = AddText(view, x, y, color, i, $"{buffer[i]:X02}") + view.Font.Width;
89+
x = AddText(context, x, y, color, i, $"{buffer[i]:X02}") + context.Font.Width;
9090
}
9191

92-
x = AddComment(view, x, y);
92+
x = AddComment(context, x, y);
9393

94-
DrawInvalidMemoryIndicatorIcon(view, y);
95-
AddContextDropDownIcon(view, y);
96-
AddDeleteIcon(view, y);
94+
DrawInvalidMemoryIndicatorIcon(context, y);
95+
AddContextDropDownIcon(context, y);
96+
AddDeleteIcon(context, y);
9797

98-
return new Size(x - origX, view.Font.Height);
98+
return new Size(x - origX, context.Font.Height);
9999
}
100100

101-
public override int CalculateDrawnHeight(DrawContext view)
101+
public override int CalculateDrawnHeight(DrawContext context)
102102
{
103-
return IsHidden && !IsWrapped ? HiddenHeight : view.Font.Height;
103+
return IsHidden && !IsWrapped ? HiddenHeight : context.Font.Height;
104104
}
105105

106106
/// <summary>Updates the node from the given spot. Sets the value of the selected byte.</summary>

0 commit comments

Comments
 (0)