summaryrefslogtreecommitdiff
path: root/plugins/Clist_modern/src/modern_rowheight_funcs.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-06-19 19:35:42 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-06-19 19:35:42 +0000
commit4c814798c7bc7f6a0f92c21b027b26290622aa2f (patch)
tree9bbfb38bd639f352300aa16ff7c45f5a9b2dba6d /plugins/Clist_modern/src/modern_rowheight_funcs.cpp
parentf0f0cd088f1ec3a85abee825ddbc214f3f6b92c3 (diff)
SIZEOF replaced with more secure analog - _countof
git-svn-id: http://svn.miranda-ng.org/main/trunk@14270 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Clist_modern/src/modern_rowheight_funcs.cpp')
-rw-r--r--plugins/Clist_modern/src/modern_rowheight_funcs.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/Clist_modern/src/modern_rowheight_funcs.cpp b/plugins/Clist_modern/src/modern_rowheight_funcs.cpp
index 5766aa8e08..aa07ffd865 100644
--- a/plugins/Clist_modern/src/modern_rowheight_funcs.cpp
+++ b/plugins/Clist_modern/src/modern_rowheight_funcs.cpp
@@ -288,7 +288,7 @@ int mod_CalcRowHeight_worker(ClcData *dat, HWND hwnd, ClcContact *contact, int i
if (item == -1) {
TCHAR szResult[80];
- if (!TimeZone_PrintDateTime(pdnce->hTimeZone, _T("t"), szResult, SIZEOF(szResult), 0)) {
+ if (!TimeZone_PrintDateTime(pdnce->hTimeZone, _T("t"), szResult, _countof(szResult), 0)) {
SIZE text_size = { 0 };
RECT rc = { 0 };
// Select font
@@ -397,7 +397,7 @@ int RowHeights_GetMaxRowHeight(ClcData *dat, HWND hwnd)
if (!dat->text_ignore_size_for_row_height) {
// Get contact font size
tmp = 0;
- for (i = 0; i < SIZEOF(contact_fonts); i++)
+ for (i = 0; i < _countof(contact_fonts); i++)
if (tmp < dat->fontModernInfo[contact_fonts[i]].fontHeight)
tmp = dat->fontModernInfo[contact_fonts[i]].fontHeight;
@@ -421,7 +421,7 @@ int RowHeights_GetMaxRowHeight(ClcData *dat, HWND hwnd)
}
// Get other font sizes
- for (i = 0; i < SIZEOF(other_fonts); i++)
+ for (i = 0; i < _countof(other_fonts); i++)
if (max_height < dat->fontModernInfo[other_fonts[i]].fontHeight)
max_height = dat->fontModernInfo[other_fonts[i]].fontHeight;
}