From 02ffd45d5cb15b7d025b9a72a21ec1fd32de8c6f Mon Sep 17 00:00:00 2001 From: Jonas Kümmerlin Date: Tue, 14 Apr 2020 17:48:45 +0200 Subject: replace GetVersion() calls with helper functions --- alf/alflabel.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'alf/alflabel.cpp') diff --git a/alf/alflabel.cpp b/alf/alflabel.cpp index c38ab08..5292a13 100644 --- a/alf/alflabel.cpp +++ b/alf/alflabel.cpp @@ -16,7 +16,7 @@ ALF__LabelTopPadding(HWND hwnd) // see also: alfedit.cpp return ALF_Compat_GetSystemMetricsForDpi( SM_CYEDGE, ALF_CentipointsToPixels(GetParent(hwnd), 7200)) - + ((LOBYTE(LOWORD(GetVersion())) < 4) ? 2 : 1) /* internal padding in edit control */; + + (!ALF_Compat_IsMinWindowsVersion(4, 0) ? 2 : 1) /* internal padding in edit control */; } static int @@ -136,7 +136,7 @@ ALF__LabelWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) SetTextColor(hdc, GetSysColor(COLOR_BTNSHADOW)); DrawText(hdc, text, -1, &rc, format); - } else if (GetVersion() >= 0x80000000) { + } else if (ALF_Compat_IsWin9x()) { // Win9x just uses gray text. DSS_DISABLED is broken there, too, // so we can't get the NT look even if we wanted to SetTextColor(hdc, GetSysColor(COLOR_GRAYTEXT)); -- cgit v1.2.3