diff options
author | ElzorFox <elzorfox@ya.ru> | 2024-04-27 21:41:39 +0500 |
---|---|---|
committer | ElzorFox <elzorfox@ya.ru> | 2024-04-27 21:41:39 +0500 |
commit | 32283350effbb57e168452ed2da6092cc83e6094 (patch) | |
tree | b3d58db3f8b2090a56ebf8165b35231a9d69e40d /protocols/VKontakte | |
parent | e55972fa316f61a21034cc6120cc475eb30de2b5 (diff) |
VKontakte: small logic fix
Diffstat (limited to 'protocols/VKontakte')
-rw-r--r-- | protocols/VKontakte/src/misc.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/protocols/VKontakte/src/misc.cpp b/protocols/VKontakte/src/misc.cpp index 3fdf4124c7..adfc14411d 100644 --- a/protocols/VKontakte/src/misc.cpp +++ b/protocols/VKontakte/src/misc.cpp @@ -1134,7 +1134,6 @@ CMStringW CVkProto::GetVkPhotoItem(const JSONNode &jnPhoto, BBCSupport iBBC, MCO case imgPreview300:
wszPreviewLink = vkSizes[wszPriorSize.Find(L"q")].wszUrl.IsEmpty() ? (vkSizes[wszPriorSize.Find(L"x")].wszUrl.IsEmpty() ? vkSizes[wszPriorSize.Find(L"o")].wszUrl : vkSizes[wszPriorSize.Find(L"x")].wszUrl) : vkSizes[wszPriorSize.Find(L"q")].wszUrl;
iPreviewHeight = vkSizes[wszPriorSize.Find(L"q")].wszUrl.IsEmpty() ? (vkSizes[wszPriorSize.Find(L"x")].wszUrl.IsEmpty() ? vkSizes[wszPriorSize.Find(L"o")].iSizeH : vkSizes[wszPriorSize.Find(L"x")].iSizeH) : vkSizes[wszPriorSize.Find(L"q")].iSizeH;
- iPreviewHeight = min(320, iPreviewHeight);
break;
case imgFullSize:
wszPreviewLink = vkSizes[iMaxSize].wszUrl;
@@ -1157,11 +1156,12 @@ CMStringW CVkProto::GetVkPhotoItem(const JSONNode &jnPhoto, BBCSupport iBBC, MCO );
- if (m_vkOptions.bBBCNewStorySupport)
+ if (m_vkOptions.bBBCNewStorySupport) {
wszPreviewLink = GetVkFileItem(wszPreviewLink, hContact, iMessageId);
+ iPreviewHeight = min(320, iPreviewHeight);
+ }
CMStringW wszImg;
-
CMStringW wszPreviewHeight(FORMAT, L" height=%d", iPreviewHeight);
if (m_vkOptions.iIMGBBCSupport && iBBC != bbcNo)
|