Skip to content

Commit d6f2a52

Browse files
Fix entry point for CopyMemory
2 parents 94cc16f + afa6cc7 commit d6f2a52

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

C64Studio/MainForm.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -503,7 +503,6 @@ public MainForm( string[] args )
503503
debugToolStripMenuItem.Visible = false;
504504
#endif
505505

506-
507506
statusProgress.Visible = false;
508507

509508
StudioCore.MainForm = this;

Common/Common/FastImage.cs

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -174,9 +174,11 @@ public override bool Equals( object Object )
174174
static extern bool InvalidateRect( IntPtr hWnd, IntPtr lpRect, bool bErase );
175175
[DllImport( "user32.dll" )]
176176
static extern bool ValidateRect( IntPtr hWnd, ref GR.Image.FastImage.RECT lpRect );
177-
178-
//[DllImport( "Kernel32.dll", EntryPoint = "CopyMemory" )]
179-
[DllImport( "Kernel32.dll", EntryPoint = "RtlCopyMemory" )] // not working in Ubuntu?
177+
#if NET5_0_OR_GREATER
178+
[DllImport( "Kernel32.dll", EntryPoint = "RtlCopyMemory" )]
179+
#else
180+
[DllImport( "Kernel32.dll", EntryPoint = "CopyMemory" )]
181+
#endif
180182
static extern void CopyMemory( IntPtr dest, IntPtr src, uint length );
181183

182184
[DllImport( "user32.dll" )]

0 commit comments

Comments
 (0)