From acb7dd27a7ab3c4551819ed29f7fe2d169d099f3 Mon Sep 17 00:00:00 2001 From: thefiddler Date: Wed, 23 Apr 2014 21:00:24 +0200 Subject: [PATCH] [Mac] Window should be invisible on startup Also fixes the initial position of the window. --- Source/OpenTK/Platform/MacOS/CocoaNativeWindow.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/OpenTK/Platform/MacOS/CocoaNativeWindow.cs b/Source/OpenTK/Platform/MacOS/CocoaNativeWindow.cs index 318d0504..66fec65b 100644 --- a/Source/OpenTK/Platform/MacOS/CocoaNativeWindow.cs +++ b/Source/OpenTK/Platform/MacOS/CocoaNativeWindow.cs @@ -179,8 +179,8 @@ namespace OpenTK.Platform.MacOS // Set up behavior Cocoa.SendIntPtr(windowPtr, Selector.Get("setDelegate:"), windowPtr); // The window class acts as its own delegate - Cocoa.SendVoid(windowPtr, Selector.Get("cascadeTopLeftFromPoint:"), new System.Drawing.PointF(20, 20)); - Cocoa.SendVoid(windowPtr, Selector.Get("makeKeyAndOrderFront:"), IntPtr.Zero); + Cocoa.SendVoid(windowPtr, Selector.Get("cascadeTopLeftFromPoint:"), System.Drawing.PointF.Empty); + Cocoa.SendVoid(windowPtr, Selector.Get("makeKeyWindow")); SetTitle(title, false); ResetTrackingArea();