Browse Source
Comparing WindowVersion with Windows8_1 instead of Windows8
Co-authored-by: Max Katz <maxkatz6@outlook.com>
pull/15810/head
Данил Юсупов
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with
2 additions and
2 deletions
-
src/Windows/Avalonia.Win32/FramebufferManager.cs
-
src/Windows/Avalonia.Win32/WindowImpl.cs
|
|
@ -88,7 +88,7 @@ namespace Avalonia.Win32 |
|
|
|
|
|
|
|
|
private Vector GetCurrentDpi() |
|
|
private Vector GetCurrentDpi() |
|
|
{ |
|
|
{ |
|
|
if (UnmanagedMethods.ShCoreAvailable && Win32Platform.WindowsVersion > PlatformConstants.Windows8) |
|
|
if (UnmanagedMethods.ShCoreAvailable && Win32Platform.WindowsVersion >= PlatformConstants.Windows8_1) |
|
|
{ |
|
|
{ |
|
|
var monitor = |
|
|
var monitor = |
|
|
UnmanagedMethods.MonitorFromWindow(_hwnd, UnmanagedMethods.MONITOR.MONITOR_DEFAULTTONEAREST); |
|
|
UnmanagedMethods.MonitorFromWindow(_hwnd, UnmanagedMethods.MONITOR.MONITOR_DEFAULTTONEAREST); |
|
|
|
|
|
@ -937,7 +937,7 @@ namespace Avalonia.Win32 |
|
|
|
|
|
|
|
|
RegisterTouchWindow(_hwnd, 0); |
|
|
RegisterTouchWindow(_hwnd, 0); |
|
|
|
|
|
|
|
|
if (ShCoreAvailable && Win32Platform.WindowsVersion > PlatformConstants.Windows8) |
|
|
if (ShCoreAvailable && Win32Platform.WindowsVersion >= PlatformConstants.Windows8_1) |
|
|
{ |
|
|
{ |
|
|
var monitor = MonitorFromWindow( |
|
|
var monitor = MonitorFromWindow( |
|
|
_hwnd, |
|
|
_hwnd, |
|
|
|