From f6ced6e8d5d0d73a9454c355c196c4ec243cf37c Mon Sep 17 00:00:00 2001 From: Joshua Coales Date: Thu, 15 Oct 2020 12:42:10 +0100 Subject: [PATCH] Raise gif maximum size to align with telegram desktop It seems that the maximum gif size on telegram desktop is 1440px. Larger than that, and it displays as a video. On iOS there is no limit to resolution, with video files up to 5000px still displaying as a gif provided there's no audio track. This change would bring the android app into line with telegram desktop, but I'm not sure whether we could scrap the resolution check, and be more inline with the iOS app? --- .../src/main/java/org/telegram/messenger/MessageObject.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TMessagesProj/src/main/java/org/telegram/messenger/MessageObject.java b/TMessagesProj/src/main/java/org/telegram/messenger/MessageObject.java index bed245799..fe3f2e113 100644 --- a/TMessagesProj/src/main/java/org/telegram/messenger/MessageObject.java +++ b/TMessagesProj/src/main/java/org/telegram/messenger/MessageObject.java @@ -2902,7 +2902,7 @@ public class MessageObject { height = attribute.h; } } - if (animated && width <= 1280 && height <= 1280) { + if (animated && width <= 1440 && height <= 1440) { return true; } }