diff --git a/Source/OpenTK/Platform/Factory.cs b/Source/OpenTK/Platform/Factory.cs index 9af6a1c5..4a7c12f5 100644 --- a/Source/OpenTK/Platform/Factory.cs +++ b/Source/OpenTK/Platform/Factory.cs @@ -99,11 +99,6 @@ namespace OpenTK.Platform { #region IPlatformFactory Members - public INativeGLWindow CreateGLNative() - { - throw new PlatformNotSupportedException("Please, refer to http://www.opentk.com for more information."); - } - public INativeWindow CreateNativeWindow(int x, int y, int width, int height, string title, GraphicsMode mode, GameWindowFlags options, DisplayDevice device) { throw new PlatformNotSupportedException("Please, refer to http://www.opentk.com for more information."); diff --git a/Source/OpenTK/Platform/MacOS/Application.cs b/Source/OpenTK/Platform/MacOS/Application.cs index 0f9923e3..7ba1054b 100644 --- a/Source/OpenTK/Platform/MacOS/Application.cs +++ b/Source/OpenTK/Platform/MacOS/Application.cs @@ -114,12 +114,12 @@ namespace OpenTK.Platform.MacOS.Carbon public static void Run(CarbonGLNative window) { - window.Destroy += MainWindowClosed; + window.Closed += MainWindowClosed; window.Visible = true; API.RunApplicationEventLoop(); - window.Destroy -= MainWindowClosed; + window.Closed -= MainWindowClosed; } static void MainWindowClosed(object sender, EventArgs e) diff --git a/Source/OpenTK/Platform/MacOS/CarbonGLNative.cs b/Source/OpenTK/Platform/MacOS/CarbonGLNative.cs index b15a9f7f..80006bc7 100644 --- a/Source/OpenTK/Platform/MacOS/CarbonGLNative.cs +++ b/Source/OpenTK/Platform/MacOS/CarbonGLNative.cs @@ -676,9 +676,6 @@ namespace OpenTK.Platform.MacOS } } - public event CreateEvent Create = delegate(object sender, EventArgs e) { }; - public event DestroyEvent Destroy = delegate(object sender, EventArgs e) { }; - #endregion #region INativeGLWindow Members diff --git a/Source/OpenTK/Platform/Windows/WinGLNative.cs b/Source/OpenTK/Platform/Windows/WinGLNative.cs index aca7c558..f91c9ee8 100644 --- a/Source/OpenTK/Platform/Windows/WinGLNative.cs +++ b/Source/OpenTK/Platform/Windows/WinGLNative.cs @@ -954,20 +954,6 @@ namespace OpenTK.Platform.Windows #endregion - #region OnDestroy - - public void OnDestroy(EventArgs e) - { - Debug.Print("Destroy event fired from window: {0}", window.ToString()); - - if (this.Destroy != null) - this.Destroy(this, e); - } - - public event DestroyEvent Destroy; - - #endregion - #endregion #region IInputDriver Members diff --git a/Source/OpenTK/Platform/X11/X11GLNative.cs b/Source/OpenTK/Platform/X11/X11GLNative.cs index 00c99692..a716eafe 100644 --- a/Source/OpenTK/Platform/X11/X11GLNative.cs +++ b/Source/OpenTK/Platform/X11/X11GLNative.cs @@ -778,6 +778,9 @@ namespace OpenTK.Platform.X11 } set { + if (value == icon) + return; + if (value == null) { Functions.XDeleteProperty(window.Display, window.WindowHandle, _atom_net_wm_icon); @@ -807,6 +810,7 @@ namespace OpenTK.Platform.X11 } icon = value; + IconChanged(this, EventArgs.Empty); } }