diff options
author | Robert Pösel <robyer@seznam.cz> | 2015-08-29 13:14:59 +0000 |
---|---|---|
committer | Robert Pösel <robyer@seznam.cz> | 2015-08-29 13:14:59 +0000 |
commit | 79c4ad2977650902c17531457721037afcfe0ac4 (patch) | |
tree | acdeb9d7485c873c46ad5f0fd13e4c482b5ec87e /plugins/Clist_modern/src | |
parent | ba6758788a83706e0b240fff7d93050656c8449e (diff) |
Clist_modern: Fix not aligning contact name when there is no avatar (broken in r14980)
Calling _GetRectangle has to be here, because it provides side-effect for positioning contact name correctly.
git-svn-id: http://svn.miranda-ng.org/main/trunk@15091 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Clist_modern/src')
-rw-r--r-- | plugins/Clist_modern/src/modern_clcpaint.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/plugins/Clist_modern/src/modern_clcpaint.cpp b/plugins/Clist_modern/src/modern_clcpaint.cpp index 03552d3690..5ccdafd151 100644 --- a/plugins/Clist_modern/src/modern_clcpaint.cpp +++ b/plugins/Clist_modern/src/modern_clcpaint.cpp @@ -2,7 +2,7 @@ Miranda NG: the free IM client for Microsoft* Windows*
-Copyright (ñ) 2012-15 Miranda NG project (http://miranda-ng.org),
+Copyright (�) 2012-15 Miranda NG project (http://miranda-ng.org),
Copyright (c) 2000-08 Miranda ICQ/IM project,
all portions of this codebase are copyrighted to the people
listed in contributors.txt.
@@ -2056,7 +2056,9 @@ void CLCPaint::_CalcItemsPos(HDC hdcMem, ClcData *dat, ClcContact *Drawing, RECT // Has to keep the empty space??
if ((left && !dat->row_align_left_items_to_left) || (!left && !dat->row_align_right_items_to_right)) {
// Make rectangle
- // RECT rc = _GetRectangle(dat, &row_rc, &free_row_rc, &left_pos, &right_pos, left, max_width, max_width, dat->avatars_maxheight_size, HORIZONTAL_SPACE);
+ // NOTE: Calling _GetRectangle on next line has to be here, because it provides side-effect for positioning contact name correctly if contact has no avatar.
+ // It makes it aligned same way as if avatar was here. Just defining rc variable is useless, as it is never used (and just shows warning).
+ /*RECT rc =*/ _GetRectangle(dat, &row_rc, &free_row_rc, &left_pos, &right_pos, left, max_width, max_width, dat->avatars_maxheight_size, HORIZONTAL_SPACE);
// Store position
//StoreItemPos( Drawing, CIT_AVATAR, &rc );
|