Skip to content

Commit

Permalink
fix differentBitSize and "more info"
Browse files Browse the repository at this point in the history
  • Loading branch information
cheat-engine committed Aug 24, 2016
1 parent 0fa72b8 commit 064d98f
Show file tree
Hide file tree
Showing 6 changed files with 124 additions and 162 deletions.
25 changes: 4 additions & 21 deletions Cheat Engine/FoundCodeUnit.pas
Original file line number Diff line number Diff line change
Expand Up @@ -494,7 +494,6 @@ procedure TFoundCodedialog.moreinfo;
lblRIP.caption:=' R8='+IntToHex(coderecord.armcontext.R8,8);

lblR9:=tlabel.Create(FormFoundCodeListExtra);
lblR9.font:=lblRCX.font;
lblR9.Top:=lblRCX.top+(lblRCX.top-lblRBX.top);
lblR9.left:=lblRCX.left;
lblR9.caption:=' R9='+IntToHex(coderecord.armcontext.R9,8);
Expand All @@ -504,7 +503,6 @@ procedure TFoundCodedialog.moreinfo;
lblR9.Align:=lblrcx.Align;

lblR10:=tlabel.Create(FormFoundCodeListExtra);
lblR10.font:=lblRCX.font;
lblR10.Top:=lblRCX.top+(lblRCX.top-lblRBX.top);
lblR10.left:=lblRDI.left;
lblR10.caption:='R10='+IntToHex(coderecord.armcontext.R10,8);
Expand All @@ -514,7 +512,6 @@ procedure TFoundCodedialog.moreinfo;
lblR10.Align:=lblrcx.Align;

lblR11:=tlabel.Create(FormFoundCodeListExtra);
lblR11.font:=lblRCX.font;
lblR11.Top:=lblRCX.top+(lblRCX.top-lblRBX.top);
lblR11.left:=lblRIP.left;
lblR11.caption:=' FP='+IntToHex(coderecord.armcontext.FP,8);
Expand All @@ -524,7 +521,6 @@ procedure TFoundCodedialog.moreinfo;
lblR11.Align:=lblrcx.Align;
//new row
lblR12:=tlabel.Create(FormFoundCodeListExtra);
lblR12.font:=lblRCX.font;
lblR12.Top:=lblR9.top+(lblRCX.top-lblRBX.top);
lblR12.left:=lblRCX.left;
lblR12.caption:=' IP='+IntToHex(coderecord.armcontext.IP,8);
Expand All @@ -534,7 +530,6 @@ procedure TFoundCodedialog.moreinfo;
lblR12.Align:=lblrcx.Align;

lblR13:=tlabel.Create(FormFoundCodeListExtra);
lblR13.font:=lblRCX.font;
lblR13.Top:=lblR9.top+(lblRCX.top-lblRBX.top);
lblR13.left:=lblRDI.left;
lblR13.caption:=' SP='+IntToHex(coderecord.armcontext.SP,8);
Expand All @@ -544,7 +539,6 @@ procedure TFoundCodedialog.moreinfo;
lblR13.Align:=lblrcx.Align;

lblR14:=tlabel.Create(FormFoundCodeListExtra);
lblR14.font:=lblRCX.font;
lblR14.Top:=lblR9.top+(lblRCX.top-lblRBX.top);
lblR14.left:=lblRIP.left;
lblR14.caption:=' LR='+IntToHex(coderecord.armcontext.LR,8);
Expand All @@ -555,7 +549,6 @@ procedure TFoundCodedialog.moreinfo;
//new line

lblR15:=tlabel.Create(FormFoundCodeListExtra);
lblR15.font:=lblRCX.font;
lblR15.Top:=lblR12.top+(lblRCX.top-lblRBX.top);
lblR15.left:=lblRCX.left;
lblR15.caption:=' PC='+IntToHex(coderecord.armcontext.PC,8);
Expand All @@ -565,7 +558,6 @@ procedure TFoundCodedialog.moreinfo;
lblR15.Align:=lblrcx.Align;

lblR16:=tlabel.Create(FormFoundCodeListExtra);
lblR16.font:=lblRCX.font;
lblR16.Top:=lblR12.top+(lblRCX.top-lblRBX.top);
lblR16.left:=lblRDI.left;
lblR16.caption:=' CPSR='+IntToHex(coderecord.armcontext.CPSR,8);
Expand All @@ -575,7 +567,6 @@ procedure TFoundCodedialog.moreinfo;
lblR16.Align:=lblrcx.Align;

lblR17:=tlabel.Create(FormFoundCodeListExtra);
lblR17.font:=lblRCX.font;
lblR17.Top:=lblR12.top+(lblRCX.top-lblRBX.top);
lblR17.left:=lblRIP.left;
lblR17.caption:=' ORIG_R0='+IntToHex(coderecord.armcontext.ORIG_R0,8);
Expand All @@ -584,9 +575,9 @@ procedure TFoundCodedialog.moreinfo;
lblR17.OnDblClick:=RegisterDblClick;
lblR17.Align:=lblrcx.Align;

Constraints.MinHeight:=panel6.top+(lblR17.top+lblR17.height)+16+panel5.height;
{Constraints.MinHeight:=panel6.top+(lblR17.top+lblR17.height)+16+panel5.height;
if height<Constraints.MinHeight then
height:=Constraints.MinHeight;
height:=Constraints.MinHeight; }
end
else
begin
Expand All @@ -610,7 +601,6 @@ procedure TFoundCodedialog.moreinfo;
pnlRegisters.ChildSizing.ControlsPerLine:=5;

lblR8:=tlabel.Create(FormFoundCodeListExtra);
lblR8.font:=lblRCX.font;
lblR8.caption:=' R8='+IntToHex(coderecord.context.r8,8);
lblR8.parent:=FormFoundCodeListExtra.pnlRegisters;
lblR8.OnMouseDown:=registerMouseDown;
Expand All @@ -619,55 +609,48 @@ procedure TFoundCodedialog.moreinfo;


lblR9:=tlabel.Create(FormFoundCodeListExtra);
lblR9.font:=lblRCX.font;
lblR9.caption:=' R9='+IntToHex(coderecord.context.r9,8);
lblR9.parent:=FormFoundCodeListExtra.pnlRegisters;
lblR9.OnMouseDown:=registerMouseDown;
lblR9.OnDblClick:=RegisterDblClick;
lblR9.Align:=lblrcx.Align;

lblR10:=tlabel.Create(FormFoundCodeListExtra);
lblR10.font:=lblRCX.font;
lblR10.caption:='R10='+IntToHex(coderecord.context.r10,8);
lblR10.parent:=FormFoundCodeListExtra.pnlRegisters;
lblR10.OnMouseDown:=registerMouseDown;
lblR10.OnDblClick:=RegisterDblClick;
lblR10.Align:=lblrcx.Align;

lblR11:=tlabel.Create(FormFoundCodeListExtra);
lblR11.font:=lblRCX.font;
lblR11.caption:='R11='+IntToHex(coderecord.context.r11,8);
lblR11.parent:=FormFoundCodeListExtra.pnlRegisters;
lblR11.OnMouseDown:=registerMouseDown;
lblR11.OnDblClick:=RegisterDblClick;
lblR11.Align:=lblrcx.Align;

lblR12:=tlabel.Create(FormFoundCodeListExtra);
lblR12.font:=lblRCX.font;
lblR12.caption:='R12='+IntToHex(coderecord.context.r12,8);
lblR12.parent:=FormFoundCodeListExtra.pnlRegisters;
lblR12.OnMouseDown:=registerMouseDown;
lblR12.OnDblClick:=RegisterDblClick;
lblR12.Align:=lblrcx.Align;

lblR13:=tlabel.Create(FormFoundCodeListExtra);
lblR13.font:=lblRCX.font;
lblR13.caption:='R13='+IntToHex(coderecord.context.r13,8);
lblR13.parent:=FormFoundCodeListExtra.pnlRegisters;
lblR13.OnMouseDown:=registerMouseDown;
lblR13.OnDblClick:=RegisterDblClick;
lblR13.Align:=lblrcx.Align;

lblR14:=tlabel.Create(FormFoundCodeListExtra);
lblR14.font:=lblRCX.font;
lblR14.caption:='R14='+IntToHex(coderecord.context.r14,8);
lblR14.parent:=FormFoundCodeListExtra.pnlRegisters;
lblR14.OnMouseDown:=registerMouseDown;
lblR14.OnDblClick:=RegisterDblClick;
lblR14.Align:=lblrcx.Align;

lblR15:=tlabel.Create(FormFoundCodeListExtra);
lblR15.font:=lblRCX.font;
lblR15.caption:='R15='+IntToHex(coderecord.context.r15,8);
lblR15.parent:=FormFoundCodeListExtra.pnlRegisters;
lblR15.OnMouseDown:=registerMouseDown;
Expand All @@ -679,9 +662,9 @@ procedure TFoundCodedialog.moreinfo;
lblRIP.BringToFront;


Constraints.MinHeight:=panel6.top+(lblR15.top+lblR15.height)+16+panel5.height;
{ Constraints.MinHeight:=panel6.top+(lblR15.top+lblR15.height)+16+panel5.height;
if height<Constraints.MinHeight then
height:=Constraints.MinHeight;
height:=Constraints.MinHeight; }
// if panel6.clientheight<lblR15.top+lblR15.height then //make room
// height:=height+(lblR15.top+lblR15.height)-(lblRDI.top+lblRDI.height);
end;
Expand Down
23 changes: 11 additions & 12 deletions Cheat Engine/formDifferentBitSizeUnit.lfm
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
object formDifferentBitSize: TformDifferentBitSize
Left = 719
Height = 128
Height = 141
Top = 250
Width = 329
VertScrollBar.Visible = False
AutoSize = True
BorderIcons = [biSystemMenu]
Caption = 'Different sized row of bits'
ClientHeight = 128
ClientHeight = 141
ClientWidth = 329
Font.Height = -11
Font.Name = 'MS Sans Serif'
OnCreate = FormCreate
OnShow = FormShow
Position = poScreenCenter
Expand All @@ -19,7 +18,7 @@ object formDifferentBitSize: TformDifferentBitSize
AnchorSideTop.Side = asrBottom
Left = 130
Height = 16
Top = 51
Top = 70
Width = 72
BorderSpacing.Top = 10
Caption = 'LabelOld'
Expand All @@ -33,7 +32,7 @@ object formDifferentBitSize: TformDifferentBitSize
AnchorSideTop.Side = asrBottom
Left = 130
Height = 16
Top = 69
Top = 88
Width = 72
BorderSpacing.Top = 2
Caption = 'LabelNew'
Expand All @@ -44,10 +43,10 @@ object formDifferentBitSize: TformDifferentBitSize
end
object Label1: TLabel
Left = 0
Height = 41
Height = 60
Top = 0
Width = 321
AutoSize = False
Width = 329
Align = alTop
Caption = 'The last time you scanned the number of bits was 90 and now it is 12. Please tell me how and how much i must change the bit offset to successfully scan. (Left arrow+right arrow move the bits)'
ParentColor = False
WordWrap = True
Expand All @@ -58,8 +57,8 @@ object formDifferentBitSize: TformDifferentBitSize
AnchorSideTop.Control = Button1
AnchorSideTop.Side = asrCenter
Left = 148
Height = 21
Top = 95
Height = 23
Top = 113
Width = 33
BorderSpacing.Top = 3
OnKeyDown = Edit1KeyDown
Expand All @@ -75,7 +74,7 @@ object formDifferentBitSize: TformDifferentBitSize
AnchorSideTop.Side = asrBottom
Left = 127
Height = 25
Top = 93
Top = 112
Width = 75
BorderSpacing.Top = 8
Caption = 'OK'
Expand Down
4 changes: 4 additions & 0 deletions Cheat Engine/formDifferentBitSizeUnit.pas
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ procedure TformDifferentBitSize.FormShow(Sender: TObject);
label1.caption:=Format(rsTheLastTimeYouScannedTheNumberOfBitsWasAndNowItIsP, [IntToStr(length(oldbit)), IntToStr(length(newbit))]);

setlength(bitscan,0);

i:=GetFontData(font.reference.Handle).Height;
Labelold.Font.Height:=i;
LabelNew.Font.Height:=i;
end;

procedure TformDifferentBitSize.Edit1KeyDown(Sender: TObject;
Expand Down
Loading

0 comments on commit 064d98f

Please sign in to comment.