diff --git a/Source/OpenTK/Graphics/DisplayDevice.cs b/Source/OpenTK/Graphics/DisplayDevice.cs index eeda0124..ef529bcc 100644 --- a/Source/OpenTK/Graphics/DisplayDevice.cs +++ b/Source/OpenTK/Graphics/DisplayDevice.cs @@ -189,10 +189,12 @@ namespace OpenTK.Graphics /// Changes the resolution of the DisplayDevice. /// The resolution to set. /// Thrown if the requested resolution could not be set. + /// If the specified resolution is null, this function will restore the original DisplayResolution. public void ChangeResolution(DisplayResolution resolution) { if (resolution == null) - throw new ArgumentNullException("resolution", "Must be a valid resolution."); + this.RestoreResolution(); + if (resolution == current_resolution) return;