Browse Source

dont crash if win32 options is cted on other platforms.

stable/0.10.0
Dan Walmsley 6 years ago
parent
commit
1a01f560cf
  1. 6
      src/Windows/Avalonia.Win32/Win32Platform.cs

6
src/Windows/Avalonia.Win32/Win32Platform.cs

@ -40,7 +40,11 @@ namespace Avalonia
public class Win32PlatformOptions
{
public bool UseDeferredRendering { get; set; } = true;
public bool AllowEglInitialization { get; set; } = Win32Platform.WindowsVersion > new Version(6, 1);
public bool AllowEglInitialization { get; set; }
= RuntimeInformation.IsOSPlatform(OSPlatform.Windows) &&
Win32Platform.WindowsVersion > new Version(6, 1);
public bool? EnableMultitouch { get; set; }
public bool OverlayPopups { get; set; }
public bool UseWgl { get; set; }

Loading…
Cancel
Save