From 486130c01ebefbe150abaa9b3c3817672f1b1c05 Mon Sep 17 00:00:00 2001 From: "Stefanos A." Date: Wed, 20 Nov 2013 13:12:42 +0100 Subject: [PATCH] Toolkit.Init() now returns a concrete class This gives us room for expansion in the future, if necessary. --- Source/OpenTK/Toolkit.cs | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/Source/OpenTK/Toolkit.cs b/Source/OpenTK/Toolkit.cs index 6f40c095..5c1c476c 100644 --- a/Source/OpenTK/Toolkit.cs +++ b/Source/OpenTK/Toolkit.cs @@ -68,9 +68,11 @@ namespace OpenTK /// /// static void Main() /// { - /// OpenTK.Toolkit.Init(); - /// ... - /// } + /// using (OpenTK.Toolkit.Init()) + /// { + /// ... + /// } + /// } /// /// /// @@ -84,7 +86,7 @@ namespace OpenTK /// An IDisposable instance that you can use to dispose of the resources /// consumed by OpenTK. /// - public static IDisposable Init() + public static Toolkit Init() { return Init(ToolkitOptions.Default); } @@ -101,9 +103,11 @@ namespace OpenTK /// /// static void Main() /// { - /// OpenTK.Toolkit.Init(); - /// ... - /// } + /// using (OpenTK.Toolkit.Init()) + /// { + /// ... + /// } + /// } /// /// /// @@ -119,7 +123,7 @@ namespace OpenTK /// An IDisposable instance that you can use to dispose of the resources /// consumed by OpenTK. /// - public static IDisposable Init(ToolkitOptions options) + public static Toolkit Init(ToolkitOptions options) { if (options == null) throw new ArgumentNullException("options");