diff options
author | George Hazan <george.hazan@gmail.com> | 2014-12-02 22:20:16 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2014-12-02 22:20:16 +0000 |
commit | 4b01e299223c3fdb05d82ecde0117f88f8caa726 (patch) | |
tree | 50f6bb91de44e402d933374ecd3766a59e382589 /plugins/Clist_nicer | |
parent | 0ca0de7698b523effaaf6cc9c608e936fa5aaf86 (diff) |
less warnings
git-svn-id: http://svn.miranda-ng.org/main/trunk@11224 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Clist_nicer')
-rw-r--r-- | plugins/Clist_nicer/src/CLCButton.cpp | 2 | ||||
-rw-r--r-- | plugins/Clist_nicer/src/clcpaint.cpp | 16 | ||||
-rw-r--r-- | plugins/Clist_nicer/src/clcutils.cpp | 8 | ||||
-rw-r--r-- | plugins/Clist_nicer/src/clui.cpp | 8 | ||||
-rw-r--r-- | plugins/Clist_nicer/src/cluiservices.cpp | 4 |
5 files changed, 19 insertions, 19 deletions
diff --git a/plugins/Clist_nicer/src/CLCButton.cpp b/plugins/Clist_nicer/src/CLCButton.cpp index 79cf53b26a..3bf670e9de 100644 --- a/plugins/Clist_nicer/src/CLCButton.cpp +++ b/plugins/Clist_nicer/src/CLCButton.cpp @@ -328,7 +328,7 @@ static void PaintWorker(MButtonExtension *ctl, HDC hdcPaint) ctl->sLabel.cx = ctl->sLabel.cy = 0;
}
else {
- GetTextExtentPoint32(hdcMem, ctl->szText, mir_tstrlen(ctl->szText), &ctl->sLabel);
+ GetTextExtentPoint32(hdcMem, ctl->szText, (int)mir_tstrlen(ctl->szText), &ctl->sLabel);
if (g_cxsmIcon + ctl->sLabel.cx + 8 > rcClient.right - rcClient.left)
ctl->sLabel.cx = (rcClient.right - rcClient.left) - g_cxsmIcon - 8;
diff --git a/plugins/Clist_nicer/src/clcpaint.cpp b/plugins/Clist_nicer/src/clcpaint.cpp index 866827d377..0c2ec8590b 100644 --- a/plugins/Clist_nicer/src/clcpaint.cpp +++ b/plugins/Clist_nicer/src/clcpaint.cpp @@ -494,7 +494,7 @@ set_bg_l: }
else if (type == CLCIT_DIVIDER) {
ChangeToFont(hdcMem, dat, FONTID_DIVIDERS, &fontHeight);
- GetTextExtentPoint32(hdcMem, contact->szText, mir_tstrlen(contact->szText), &textSize);
+ GetTextExtentPoint32(hdcMem, contact->szText, (int)mir_tstrlen(contact->szText), &textSize);
}
else if (type == CLCIT_CONTACT && flags & CONTACTF_NOTONLIST)
ChangeToFont(hdcMem, dat, FONTID_NOTONLIST, &fontHeight);
@@ -509,13 +509,13 @@ set_bg_l: ChangeToFont(hdcMem, dat, FONTID_CONTACTS, &fontHeight);
if (type == CLCIT_GROUP) {
- GetTextExtentPoint32(hdcMem, contact->szText, mir_tstrlen(contact->szText), &textSize);
+ GetTextExtentPoint32(hdcMem, contact->szText, (int)mir_tstrlen(contact->szText), &textSize);
width = textSize.cx;
szCounts = pcli->pfnGetGroupCountsText(dat, contact);
if (szCounts[0]) {
GetTextExtentPoint32(hdcMem, _T(" "), 1, &spaceSize);
ChangeToFont(hdcMem, dat, FONTID_GROUPCOUNTS, &fontHeight);
- GetTextExtentPoint32A(hdcMem, szCounts, mir_strlen(szCounts), &countsSize);
+ GetTextExtentPoint32A(hdcMem, szCounts, (int)mir_strlen(szCounts), &countsSize);
width += spaceSize.cx + countsSize.cx;
}
}
@@ -977,7 +977,7 @@ bgskipped: rc.left = rcContent.left;
rc.right = rc.left - dat->rightMargin + ((clRect->right - rc.left - textSize.cx) >> 1) - 3;
DrawEdge(hdcMem, &rc, BDR_SUNKENOUTER, BF_RECT);
- TextOut(hdcMem, rc.right + 3, y + ((rowHeight - fontHeight) >> 1), contact->szText, mir_tstrlen(contact->szText));
+ TextOut(hdcMem, rc.right + 3, y + ((rowHeight - fontHeight) >> 1), contact->szText, (int)mir_tstrlen(contact->szText));
rc.left = rc.right + 6 + textSize.cx;
rc.right = clRect->right - dat->rightMargin;
DrawEdge(hdcMem, &rc, BDR_SUNKENOUTER, BF_RECT);
@@ -1012,7 +1012,7 @@ bgskipped: if (g_center)
offset = ((rc.right - rc.left) - labelWidth) / 2;
- TextOutA(hdcMem, rc.left + offset + textSize.cx + spaceSize.cx, rc.top + groupCountsFontTopShift, szCounts, mir_strlen(szCounts));
+ TextOutA(hdcMem, rc.left + offset + textSize.cx + spaceSize.cx, rc.top + groupCountsFontTopShift, szCounts, (int)mir_strlen(szCounts));
rightLineStart = rc.left + offset + textSize.cx + spaceSize.cx + countsSize.cx + 2;
if (selected && !g_ignoreselforgroups)
@@ -1121,7 +1121,7 @@ bgskipped: COLORREF oldColor = GetTextColor(hdcMem);
int idOldFont = dat->currentFontID;
ChangeToFont(hdcMem, dat, FONTID_TIMESTAMP, &fHeight);
- GetTextExtentPoint32(hdcMem, szResult, mir_tstrlen(szResult), &szTime);
+ GetTextExtentPoint32(hdcMem, szResult, (int)mir_tstrlen(szResult), &szTime);
verticalfit = (rowHeight - fHeight >= g_cysmIcon+1);
if (av_right) {
@@ -1203,7 +1203,7 @@ nodisplay: LONG rightIconsTop = rcContent.bottom - g_cysmIcon;
LONG old_right = rcContent.right;
ULONG textCounter = 0;
- ULONG ulLen = mir_tstrlen(szText);
+ size_t ulLen = mir_tstrlen(szText);
LONG old_bottom = rcContent.bottom;
DWORD i_dtFlags = DT_WORDBREAK | DT_NOPREFIX | dt_2ndrowflags;
dtp.cbSize = sizeof(dtp);
@@ -1229,7 +1229,7 @@ nodisplay: if (type != CLCIT_DIVIDER) {
TCHAR *szText = contact->szText;
RECT rc;
- int qlen = mir_tstrlen(dat->szQuickSearch);
+ int qlen = (int)mir_tstrlen(dat->szQuickSearch);
if (hPreviousFont)
SelectObject(hdcMem, hPreviousFont);
SetTextColor(hdcMem, dat->quickSearchColour);
diff --git a/plugins/Clist_nicer/src/clcutils.cpp b/plugins/Clist_nicer/src/clcutils.cpp index f8026b4d2e..4f90f28bdf 100644 --- a/plugins/Clist_nicer/src/clcutils.cpp +++ b/plugins/Clist_nicer/src/clcutils.cpp @@ -164,7 +164,7 @@ int RTL_HitTest(HWND hwnd, struct ClcData *dat, int testx, int testy, ClcContact hFont = reinterpret_cast<HFONT>(SelectObject(hdc, dat->fontInfo[FONTID_GROUPS].hFont));
else
hFont = reinterpret_cast<HFONT>(SelectObject(hdc, dat->fontInfo[FONTID_CONTACTS].hFont));
- GetTextExtentPoint32(hdc, hitcontact->szText, mir_tstrlen(hitcontact->szText), &textSize);
+ GetTextExtentPoint32(hdc, hitcontact->szText, (int)mir_tstrlen(hitcontact->szText), &textSize);
width = textSize.cx;
if (hitcontact->type == CLCIT_GROUP) {
char *szCounts;
@@ -173,7 +173,7 @@ int RTL_HitTest(HWND hwnd, struct ClcData *dat, int testx, int testy, ClcContact GetTextExtentPoint32A(hdc, " ", 1, &textSize);
width += textSize.cx;
SelectObject(hdc, dat->fontInfo[FONTID_GROUPCOUNTS].hFont);
- GetTextExtentPoint32A(hdc, szCounts, mir_strlen(szCounts), &textSize);
+ GetTextExtentPoint32A(hdc, szCounts, (int)mir_strlen(szCounts), &textSize);
width += textSize.cx;
}
}
@@ -305,7 +305,7 @@ int HitTest(HWND hwnd, struct ClcData *dat, int testx, int testy, ClcContact **c hFont = reinterpret_cast<HFONT>(SelectObject(hdc, dat->fontInfo[FONTID_GROUPS].hFont));
else
hFont = reinterpret_cast<HFONT>(SelectObject(hdc, dat->fontInfo[FONTID_CONTACTS].hFont));
- GetTextExtentPoint32(hdc, hitcontact->szText, mir_tstrlen(hitcontact->szText), &textSize);
+ GetTextExtentPoint32(hdc, hitcontact->szText, (int)mir_tstrlen(hitcontact->szText), &textSize);
width = textSize.cx;
if (hitcontact->type == CLCIT_GROUP) {
char *szCounts;
@@ -314,7 +314,7 @@ int HitTest(HWND hwnd, struct ClcData *dat, int testx, int testy, ClcContact **c GetTextExtentPoint32A(hdc, " ", 1, &textSize);
width += textSize.cx;
SelectObject(hdc, dat->fontInfo[FONTID_GROUPCOUNTS].hFont);
- GetTextExtentPoint32A(hdc, szCounts, mir_strlen(szCounts), &textSize);
+ GetTextExtentPoint32A(hdc, szCounts, (int)mir_strlen(szCounts), &textSize);
width += textSize.cx;
}
}
diff --git a/plugins/Clist_nicer/src/clui.cpp b/plugins/Clist_nicer/src/clui.cpp index 593b765869..9db9a3bfa1 100644 --- a/plugins/Clist_nicer/src/clui.cpp +++ b/plugins/Clist_nicer/src/clui.cpp @@ -1773,14 +1773,14 @@ buttons_done: if (mir_tstrlen(szName) < sizeof(szName) - 1) mir_tstrcat(szName, _T(" ")); - GetTextExtentPoint32(dis->hDC, szName, mir_tstrlen(szName), &textSize); - TextOut(dis->hDC, x, (dis->rcItem.top + dis->rcItem.bottom - textSize.cy) >> 1, szName, mir_tstrlen(szName)); + GetTextExtentPoint32(dis->hDC, szName, (int)mir_tstrlen(szName), &textSize); + TextOut(dis->hDC, x, (dis->rcItem.top + dis->rcItem.bottom - textSize.cy) >> 1, szName, (int)mir_tstrlen(szName)); x += textSize.cx; } if (showOpts & 4) { TCHAR *szStatus = pcli->pfnGetStatusModeDescription(status, 0); - GetTextExtentPoint32(dis->hDC, szStatus, mir_tstrlen(szStatus), &textSize); - TextOut(dis->hDC, x, (dis->rcItem.top + dis->rcItem.bottom - textSize.cy) >> 1, szStatus, mir_tstrlen(szStatus)); + GetTextExtentPoint32(dis->hDC, szStatus, (int)mir_tstrlen(szStatus), &textSize); + TextOut(dis->hDC, x, (dis->rcItem.top + dis->rcItem.bottom - textSize.cy) >> 1, szStatus, (int)mir_tstrlen(szStatus)); } } else if (dis->CtlType == ODT_MENU) { diff --git a/plugins/Clist_nicer/src/cluiservices.cpp b/plugins/Clist_nicer/src/cluiservices.cpp index d7ed5ed41c..832a308d4f 100644 --- a/plugins/Clist_nicer/src/cluiservices.cpp +++ b/plugins/Clist_nicer/src/cluiservices.cpp @@ -144,12 +144,12 @@ void CluiProtocolStatusChanged( int parStatus, const char* szProto ) szName[ SIZEOF(szName)-1 ] = 0;
if (( showOpts & 4 ) && mir_tstrlen(szName) < sizeof(szName)-1 )
mir_tstrcat( szName, _T(" "));
- GetTextExtentPoint32( hdc, szName, mir_tstrlen(szName), &textSize );
+ GetTextExtentPoint32( hdc, szName, (int)mir_tstrlen(szName), &textSize );
x += textSize.cx + GetSystemMetrics(SM_CXBORDER) * 4; // The SB panel doesnt allocate enough room
}
if (showOpts & 4) {
TCHAR* modeDescr = pcli->pfnGetStatusModeDescription( CallProtoService(accs[i]->szModuleName,PS_GETSTATUS,0,0 ), 0 );
- GetTextExtentPoint32(hdc, modeDescr, mir_tstrlen(modeDescr), &textSize );
+ GetTextExtentPoint32(hdc, modeDescr, (int)mir_tstrlen(modeDescr), &textSize );
x += textSize.cx + GetSystemMetrics(SM_CXBORDER) * 4; // The SB panel doesnt allocate enough room
}
partWidths[partCount]=(partCount?partWidths[partCount-1]:cfg::dat.bCLeft)+ x + 2;
|