summaryrefslogtreecommitdiff
path: root/plugins/Quotes/src/Chart.h
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2014-12-02 21:55:57 +0000
committerGeorge Hazan <george.hazan@gmail.com>2014-12-02 21:55:57 +0000
commit0ca0de7698b523effaaf6cc9c608e936fa5aaf86 (patch)
tree1e6ce038dc27a1ccddb5e3f863607c83eece2e98 /plugins/Quotes/src/Chart.h
parentaeae01dc50a5adea8fe003c8195540b1f2b2169f (diff)
useless calls of mir_*strlen in DrawText replaced with -1
git-svn-id: http://svn.miranda-ng.org/main/trunk@11223 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Quotes/src/Chart.h')
-rw-r--r--plugins/Quotes/src/Chart.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/Quotes/src/Chart.h b/plugins/Quotes/src/Chart.h
index 8c40a4dfff..4e00d3cba4 100644
--- a/plugins/Quotes/src/Chart.h
+++ b/plugins/Quotes/src/Chart.h
@@ -91,7 +91,7 @@ public:
HFONT hOldFont = static_cast<HFONT>(::SelectObject(hdc,hFont));
LPCTSTR pszText = TranslateT("There is no to show");
- int nDrawTextResult = ::DrawText(hdc,pszText,::mir_tstrlen(pszText),&rc,DT_SINGLELINE|DT_VCENTER|DT_CENTER);
+ int nDrawTextResult = ::DrawText(hdc, pszText, -1, &rc, DT_SINGLELINE | DT_VCENTER | DT_CENTER);
assert(0 != nDrawTextResult);
::SelectObject(hdc,hOldFont);
@@ -132,7 +132,7 @@ private:
y_val = m_MinY + ((m_MaxY-m_MinY)/number_of_lines);
nXIndent += 2;
rc.left += nXIndent;
- for(int y = rc.bottom-step;y > rc.top;y-=step,y_val+=((m_MaxY-m_MinY)/number_of_lines))
+ for (int y = rc.bottom-step;y > rc.top;y-=step,y_val+=((m_MaxY-m_MinY)/number_of_lines))
{
tstring sY = TYConverter::ToString(y_val);
SIZE sizeText = {0,0};
@@ -140,7 +140,7 @@ private:
assert(TRUE == bResult);
RECT rcText = {rc.left-nXIndent,y-(sizeText.cy/2),rc.left-1,y+(sizeText.cy/2)};
- int nDrawTextResult = ::DrawText(hdc, sY.c_str(), (int)sY.size(), &rcText, DT_SINGLELINE|DT_VCENTER|DT_RIGHT);
+ int nDrawTextResult = ::DrawText(hdc, sY.c_str(), -1, &rcText, DT_SINGLELINE|DT_VCENTER|DT_RIGHT);
assert(0 != nDrawTextResult);
bResult = ::MoveToEx(hdc,rc.left,y,NULL);