summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugins/SpellChecker/src/utils.cpp16
1 files changed, 2 insertions, 14 deletions
diff --git a/plugins/SpellChecker/src/utils.cpp b/plugins/SpellChecker/src/utils.cpp
index 83884c35ae..0baf6bc842 100644
--- a/plugins/SpellChecker/src/utils.cpp
+++ b/plugins/SpellChecker/src/utils.cpp
@@ -35,19 +35,7 @@ void SetUnderline(Dialog *dlg, int pos_start, int pos_end)
cf.dwEffects = CFE_UNDERLINE;
cf.bUnderlineType = opts.underline_type + CFU_UNDERLINEDOUBLE;
- OSVERSIONINFOEX osvi = { 0 };
- BOOL bOsVersionInfoEx;
-
- osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFOEX);
-
- bOsVersionInfoEx = GetVersionEx((OSVERSIONINFO*)&osvi);
- if (!bOsVersionInfoEx) {
- osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
- if (!GetVersionEx((OSVERSIONINFO*)&osvi))
- return;
- }
-
- if (VER_PLATFORM_WIN32_NT == osvi.dwPlatformId && osvi.dwMajorVersion == 6 && osvi.dwMinorVersion >= 2)
+ if (IsWinVer8Plus())
cf.bUnderlineColor = 0x06;
else
cf.bUnderlineColor = 0x05;
@@ -1063,7 +1051,7 @@ void AppendMenuItem(HMENU hMenu, int id, TCHAR *name, HICON hIcon, BOOL checked)
GetIconInfo(hIcon, &iconInfo);
MENUITEMINFO mii = { 0 };
- mii.cbSize = sizeof(mii);
+ mii.cbSize = sizeof(mii);
mii.fMask = MIIM_CHECKMARKS | MIIM_TYPE | MIIM_STATE;
mii.fType = MFT_STRING;
mii.fState = (checked ? MFS_CHECKED : 0);