From: Stefanos A. Date: Fri, 27 Sep 2013 16:55:38 +0000 (+0200) Subject: Use Wgl.Import.GetCurrentContext DllImport directly X-Git-Tag: 1.1-b1~322 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=339890294057abd38c550f50468c45a1bdcb396a;p=platform%2Fcore%2Fcsapi%2Fopentk.git Use Wgl.Import.GetCurrentContext DllImport directly Wgl is implemented using the regular DllImport + delegate approach, in order to support extensions. The delegates have not been armed at this point, so we need to use the DllImport directly. The whole wgl API should be revisited (we are using only a tiny portion.) --- diff --git a/Source/OpenTK/Platform/SDL2/Sdl2Factory.cs b/Source/OpenTK/Platform/SDL2/Sdl2Factory.cs index 46870ea0..cc3fa753 100644 --- a/Source/OpenTK/Platform/SDL2/Sdl2Factory.cs +++ b/Source/OpenTK/Platform/SDL2/Sdl2Factory.cs @@ -40,7 +40,7 @@ namespace OpenTK.Platform.SDL2 { IntPtr current; if (Configuration.RunningOnWindows) - current = OpenTK.Platform.Windows.Wgl.GetCurrentContext(); + current = OpenTK.Platform.Windows.Wgl.Imports.GetCurrentContext(); else if (Configuration.RunningOnX11) current = OpenTK.Platform.X11.Glx.GetCurrentContext(); else if (Configuration.RunningOnMacOS)