summaryrefslogtreecommitdiff
path: root/src/modules/utils/resizer.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-06-14 15:51:34 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-06-14 15:51:34 +0000
commite58823d961a630eb62e60d2ccb443761ba5f1704 (patch)
tree62d071be480d57af2a53f154a1468abe0b9449ff /src/modules/utils/resizer.cpp
parent721aea0764451e985d575236205808bbef298244 (diff)
- all MS_CLIST_ADD*ITEM services replaced with Menu_Add*Item stubs.
- massive cleanup of the menu-related code git-svn-id: http://svn.miranda-ng.org/main/trunk@410 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'src/modules/utils/resizer.cpp')
-rw-r--r--src/modules/utils/resizer.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/modules/utils/resizer.cpp b/src/modules/utils/resizer.cpp
index b68e874753..1ddfa3fb75 100644
--- a/src/modules/utils/resizer.cpp
+++ b/src/modules/utils/resizer.cpp
@@ -11,7 +11,7 @@ modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.
-This program is distributed in the hope that it will be useful,
+This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
@@ -59,10 +59,10 @@ INT_PTR ResizeDialog(WPARAM, LPARAM lParam)
START_OF_DLGTEMPLATEEX *pTemplateEx;
UTILRESIZECONTROL urc;
int procResult;
- int extendedDlg,itemCount;
+ int extendedDlg, itemCount;
if (urd == NULL||urd->cbSize != sizeof(UTILRESIZEDIALOG)) return 1;
- pTemplate=(DLGTEMPLATE*)LockResource(LoadResource(urd->hInstance,FindResourceA(urd->hInstance,urd->lpTemplate,MAKEINTRESOURCEA(5))));
+ pTemplate=(DLGTEMPLATE*)LockResource(LoadResource(urd->hInstance, FindResourceA(urd->hInstance, urd->lpTemplate, MAKEINTRESOURCEA(5))));
pTemplateEx=(START_OF_DLGTEMPLATEEX*)pTemplate;
extendedDlg=pTemplateEx->signature == 0xFFFF;
if (extendedDlg && pTemplateEx->dlgVer != 1)
@@ -75,7 +75,7 @@ INT_PTR ResizeDialog(WPARAM, LPARAM lParam)
while (*pWord++); //title
if (extendedDlg) {
if (pTemplateEx->style&DS_SETFONT) {
- pWord+=3; //font size,weight,italic
+ pWord+=3; //font size, weight, italic
while (*pWord++); //font name
}
}
@@ -90,9 +90,9 @@ INT_PTR ResizeDialog(WPARAM, LPARAM lParam)
rc.left=0; rc.top=0;
if (extendedDlg) {rc.right=pTemplateEx->cx; rc.bottom=pTemplateEx->cy;}
else {rc.right=pTemplate->cx; rc.bottom=pTemplate->cy;}
- MapDialogRect(urd->hwndDlg,&rc);
+ MapDialogRect(urd->hwndDlg, &rc);
urc.dlgOriginalSize.cx=rc.right; urc.dlgOriginalSize.cy=rc.bottom;
- GetClientRect(urd->hwndDlg,&rc);
+ GetClientRect(urd->hwndDlg, &rc);
urc.dlgNewSize.cx=rc.right; urc.dlgNewSize.cy=rc.bottom;
if (extendedDlg) itemCount=pTemplateEx->cDlgItems;
@@ -123,8 +123,8 @@ INT_PTR ResizeDialog(WPARAM, LPARAM lParam)
if (urc.wId == 65535) continue; //using this breaks the dwp, so just ignore it
- MapDialogRect(urd->hwndDlg,&urc.rcItem);
- procResult=(urd->pfnResizer)(urd->hwndDlg,urd->lParam,&urc);
+ MapDialogRect(urd->hwndDlg, &urc.rcItem);
+ procResult=(urd->pfnResizer)(urd->hwndDlg, urd->lParam, &urc);
if (procResult&RD_ANCHORX_RIGHT) {
urc.rcItem.left+=urc.dlgNewSize.cx-urc.dlgOriginalSize.cx;
urc.rcItem.right+=urc.dlgNewSize.cx-urc.dlgOriginalSize.cx;
@@ -145,7 +145,7 @@ INT_PTR ResizeDialog(WPARAM, LPARAM lParam)
urc.rcItem.top+=(urc.dlgNewSize.cy-urc.dlgOriginalSize.cy)/2;
urc.rcItem.bottom+=(urc.dlgNewSize.cy-urc.dlgOriginalSize.cy)/2;
}
- hDwp = DeferWindowPos(hDwp,GetDlgItem(urd->hwndDlg,extendedDlg?pItemEx->id:pItem->id),0,urc.rcItem.left,urc.rcItem.top,urc.rcItem.right-urc.rcItem.left,urc.rcItem.bottom-urc.rcItem.top,SWP_NOZORDER);
+ hDwp = DeferWindowPos(hDwp, GetDlgItem(urd->hwndDlg, extendedDlg?pItemEx->id:pItem->id), 0, urc.rcItem.left, urc.rcItem.top, urc.rcItem.right-urc.rcItem.left, urc.rcItem.bottom-urc.rcItem.top, SWP_NOZORDER);
}
EndDeferWindowPos(hDwp);
return 0;