Allow videos to have size as before streaming.

Fixes #6915.
This commit is contained in:
John Preston 2019-12-31 14:56:31 +03:00
parent 735457c231
commit 22df6fb42e
1 changed files with 6 additions and 2 deletions

View File

@ -111,7 +111,9 @@ QSize Gif::countOptimalSize() {
_parent->skipBlockHeight());
}
const auto maxSize = _data->isVideoMessage()
const auto maxSize = _data->isVideoFile()
? st::maxMediaSize
: _data->isVideoMessage()
? st::maxVideoMessageSize
: st::maxGifSize;
const auto size = style::ConvertScale(videoSize());
@ -160,7 +162,9 @@ QSize Gif::countOptimalSize() {
QSize Gif::countCurrentSize(int newWidth) {
auto availableWidth = newWidth;
const auto maxSize = _data->isVideoMessage()
const auto maxSize = _data->isVideoFile()
? st::maxMediaSize
: _data->isVideoMessage()
? st::maxVideoMessageSize
: st::maxGifSize;
const auto size = style::ConvertScale(videoSize());