diff options
Diffstat (limited to 'plugins/Popup/src/avatars_simple.cpp')
-rw-r--r-- | plugins/Popup/src/avatars_simple.cpp | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/plugins/Popup/src/avatars_simple.cpp b/plugins/Popup/src/avatars_simple.cpp index 86c9b6dd15..ab5edadbf6 100644 --- a/plugins/Popup/src/avatars_simple.cpp +++ b/plugins/Popup/src/avatars_simple.cpp @@ -2,9 +2,9 @@ Popup Plus plugin for Miranda IM
Copyright © 2002 Luca Santarelli,
- © 2004-2007 Victor Pavlychko
- © 2010 MPK
- © 2010 Merlin_de
+© 2004-2007 Victor Pavlychko
+© 2010 MPK
+© 2010 Merlin_de
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
@@ -24,7 +24,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include "headers.h"
SimpleAvatar::SimpleAvatar(HANDLE h, bool bUseBitmap) :
- PopupAvatar((bUseBitmap) ? 0 : h)
+PopupAvatar()
{
bIsAnimated = false;
bIsValid = true;
@@ -85,11 +85,12 @@ void SimpleAvatar::draw(MyBitmap *bmp, int x, int y, int w, int h, POPUPOPTIONS HRGN rgn;
if (options->avatarRadius)
{
- rgn = CreateRoundRectRgn(x, y, x+w, y+h, 2 * options->avatarRadius, 2 * options->avatarRadius);
+ rgn = CreateRoundRectRgn(x, y, x + w, y + h, 2 * options->avatarRadius, 2 * options->avatarRadius);
SelectClipRgn(bmp->getDC(), rgn);
- } else
+ }
+ else
{
- rgn = CreateRectRgn(x, y, x+w, y+h);
+ rgn = CreateRectRgn(x, y, x + w, y + h);
}
HDC hdcTmp = CreateCompatibleDC(bmp->getDC());
@@ -110,7 +111,7 @@ void SimpleAvatar::draw(MyBitmap *bmp, int x, int y, int w, int h, POPUPOPTIONS {
HBRUSH hbr = CreateSolidBrush(fonts.clAvatarBorder);
bmp->saveAlpha(x, y, w, h);
- FrameRgn(bmp->getDC(), rgn, hbr, 1, 1);
+ FrameRgn(bmp->getDC(), rgn, hbr, 1, 1);
DeleteObject(hbr);
bmp->restoreAlpha(x, y, w, h);
}
@@ -120,7 +121,7 @@ void SimpleAvatar::draw(MyBitmap *bmp, int x, int y, int w, int h, POPUPOPTIONS StretchBlt(bmp->getDC(), x, y, w, h, hdcTmp, 0, 0, av->bmWidth, av->bmHeight, SRCCOPY);
if (options->avatarBorders){
HBRUSH hbr = CreateSolidBrush(fonts.clAvatarBorder);
- FrameRgn(bmp->getDC(), rgn, hbr, 1, 1);
+ FrameRgn(bmp->getDC(), rgn, hbr, 1, 1);
DeleteObject(hbr);
}
bmp->restoreAlpha(x, y, w, h);
|