Make Mono use X11GdiPlusInternals regardless of platform.

This commit is contained in:
the_fiddler 2009-02-12 22:48:09 +00:00
parent 64dfa91678
commit 44240ad598
2 changed files with 4 additions and 2 deletions

View file

@ -26,10 +26,10 @@ namespace OpenTK.Platform
static GdiPlus()
{
if (Configuration.RunningOnWindows)
if (Configuration.RunningOnWindows && !Configuration.RunningOnMono)
internals = new Windows.WinGdiPlusInternals();
else
internals = new X11.X11GdiPlusInternals();
internals = new X11.X11GdiPlusInternals(); // This class is Mono-specific and works on all platforms.
}
#endregion

View file

@ -14,6 +14,8 @@ using System.Reflection;
namespace OpenTK.Platform.X11
{
// Note: This class is Mono-specific, not X11-specific!
// It works on all platforms (windows, linux, macos) as long as we are running on Mono.
class X11GdiPlusInternals : IGdiPlusInternals
{
static readonly PropertyInfo native_graphics_property, native_font_property, native_string_format_property;