summaryrefslogtreecommitdiff
path: root/plugins/IEView/src
diff options
context:
space:
mode:
authorKirill Volinsky <mataes2007@gmail.com>2013-03-16 10:40:04 +0000
committerKirill Volinsky <mataes2007@gmail.com>2013-03-16 10:40:04 +0000
commitb376d5d7718b091ae2c2179ebac5168cf2dfcdad (patch)
tree7036f0adfe77fb0aa2a7bcddec91b956064ca4f2 /plugins/IEView/src
parent801eda9430588adbdc99e7d3ed0adf8cc5cbc49f (diff)
fixed checking jpg format if png not founded
git-svn-id: http://svn.miranda-ng.org/main/trunk@4061 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/IEView/src')
-rw-r--r--plugins/IEView/src/TemplateHTMLBuilder.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/plugins/IEView/src/TemplateHTMLBuilder.cpp b/plugins/IEView/src/TemplateHTMLBuilder.cpp
index 6a65eab30c..247b927888 100644
--- a/plugins/IEView/src/TemplateHTMLBuilder.cpp
+++ b/plugins/IEView/src/TemplateHTMLBuilder.cpp
@@ -200,12 +200,12 @@ void TemplateHTMLBuilder::buildHeadTemplate(IEView *view, IEVIEWEVENT *event, Pr
szNameIn = Utils::dupString("&nbsp;");
}
sprintf(tempStr, "%snoavatar.png", tempBase);
+ szNoAvatar = Utils::UTF8Encode(tempStr);
+ if (access(szNoAvatar, 0) == -1)
+ {
+ sprintf(tempStr, "%snoavatar.jpg", tempBase);
szNoAvatar = Utils::UTF8Encode(tempStr);
- if (access(szNoAvatar, 0) != -1)
- {
- sprintf(tempStr, "%snoavatar.jpg", tempBase);
- szNoAvatar = Utils::UTF8Encode(tempStr);
- }
+ }
szAvatarIn = getAvatar(event->hContact, szRealProto);
if (szAvatarIn == NULL) {
szAvatarIn = Utils::dupString(szNoAvatar);
@@ -376,12 +376,12 @@ void TemplateHTMLBuilder::appendEventTemplate(IEView *view, IEVIEWEVENT *event,
szNameIn = Utils::dupString("&nbsp;");
}
sprintf(tempStr, "%snoavatar.png", tempBase);
+ szNoAvatar = Utils::UTF8Encode(tempStr);
+ if (access(szNoAvatar, 0) == -1)
+ {
+ sprintf(tempStr, "%snoavatar.jpg", tempBase);
szNoAvatar = Utils::UTF8Encode(tempStr);
- if (access(szNoAvatar, 0) != -1)
- {
- sprintf(tempStr, "%snoavatar.jpg", tempBase);
- szNoAvatar = Utils::UTF8Encode(tempStr);
- }
+ }
if(event->hContact != NULL) {
szAvatarIn = getAvatar(event->hContact, szRealProto);