mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2026-07-25 06:54:43 +00:00
Reverted "Fixed inline results disappearing when media dimensions..."
This reverts commit 6df0333ca2.
This commit is contained in:
@@ -128,9 +128,8 @@ Gif::Gif(
|
||||
void Gif::initDimensions() {
|
||||
int32 w = content_width(), h = content_height();
|
||||
if (w <= 0 || h <= 0) {
|
||||
w = h = 1;
|
||||
}
|
||||
{
|
||||
_maxw = 0;
|
||||
} else {
|
||||
w = w * st::inlineMediaHeight / h;
|
||||
_maxw = qMax(w, int32(st::inlineResultsMinWidth));
|
||||
}
|
||||
@@ -679,9 +678,8 @@ void Photo::initDimensions() {
|
||||
const auto photo = getShownPhoto();
|
||||
int32 w = photo->width(), h = photo->height();
|
||||
if (w <= 0 || h <= 0) {
|
||||
w = h = 1;
|
||||
}
|
||||
{
|
||||
_maxw = 0;
|
||||
} else {
|
||||
w = w * st::inlineMediaHeight / h;
|
||||
_maxw = qMax(w, int32(st::inlineResultsMinWidth));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user