Fix sticker suggestions by emoji.

Regression was introduced in 27f248645c.
This commit is contained in:
John Preston 2019-07-28 15:45:46 +02:00
parent 27d84befa8
commit 32e8ae2b9e

View file

@ -646,7 +646,7 @@ void FieldAutocompleteInner::paintEvent(QPaintEvent *e) {
w = std::max(size.width(), 1); w = std::max(size.width(), 1);
h = std::max(size.height(), 1); h = std::max(size.height(), 1);
} else { } else {
const auto coef = std::max( const auto coef = std::min(
std::min( std::min(
(st::stickerPanSize.width() - st::buttonRadius * 2) / float64(document->dimensions.width()), (st::stickerPanSize.width() - st::buttonRadius * 2) / float64(document->dimensions.width()),
(st::stickerPanSize.height() - st::buttonRadius * 2) / float64(document->dimensions.height())), (st::stickerPanSize.height() - st::buttonRadius * 2) / float64(document->dimensions.height())),