Skip to content

Commit

Permalink
Fix: Custom cursors not working under OS-X and dotnet (#797)
Browse files Browse the repository at this point in the history
Rebased version of #764
  • Loading branch information
leezer3 authored and Nihlus committed Aug 14, 2018
1 parent 05d86f7 commit eab88bf
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/OpenTK/Platform/MacOS/Cocoa/Cocoa.cs
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public static extern IntPtr SendIntPtr(IntPtr receiver, IntPtr selector, NSRect

[DllImport(LibObjC, EntryPoint = "objc_msgSend")]
public static extern IntPtr SendIntPtr(IntPtr receiver, IntPtr selector, IntPtr p1, int p2, int p3, int p4,
int p5, int p6, int p7, IntPtr p8, NSBitmapFormat p9, int p10, int p11);
int p5, bool p6, bool p7, IntPtr p8, NSBitmapFormat p9, int p10, int p11);

[DllImport(LibObjC, EntryPoint = "objc_msgSend")]
public static extern bool SendBool(IntPtr receiver, IntPtr selector);
Expand Down
6 changes: 3 additions & 3 deletions src/OpenTK/Platform/MacOS/CocoaNativeWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1108,15 +1108,15 @@ private static IntPtr ToNSCursor(MouseCursor cursor)
cursor.Height,
8,
4,
1,
0,
true,
false,
NSDeviceRGBColorSpace,
NSBitmapFormat.AlphaFirst,
4 * cursor.Width,
32);
if (imgdata == IntPtr.Zero)
{
Debug.Print("Failed to create NSBitmapImageRep with size ({0},{1]})",
Debug.Print("Failed to create NSBitmapImageRep with size ({0},{1})",
cursor.Width, cursor.Height);
return IntPtr.Zero;
}
Expand Down

0 comments on commit eab88bf

Please sign in to comment.