Update to 5.13.0 (1820)

Merged some parts of https://github.com/DrKLO/Telegram/pull/1541
This commit is contained in:
DrKLO 2020-01-01 21:32:12 +03:00
parent cc1dc35742
commit 1eea3ab6f7
25 changed files with 206 additions and 105 deletions

View file

@ -7198,11 +7198,11 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
final ViewGroup.LayoutParams layoutParams = animatingImageView.getLayoutParams();
layoutParams.width = (int) drawRegion.width();
layoutParams.height = (int) drawRegion.height();
if (layoutParams.width == 0) {
layoutParams.width = 1;
if (layoutParams.width <= 0) {
layoutParams.width = 100;
}
if (layoutParams.height == 0) {
layoutParams.height = 1;
if (layoutParams.height <= 0) {
layoutParams.height = 100;
}
for (int i = 0; i < animatingImageViews.length; i++) {
@ -7570,11 +7570,11 @@ public class PhotoViewer implements NotificationCenter.NotificationCenterDelegat
animatingImageViews[i].setImageBitmap(centerImage.getBitmapSafe());
}
}
if (layoutParams.width == 0) {
layoutParams.width = 1;
if (layoutParams.width <= 0) {
layoutParams.width = 100;
}
if (layoutParams.height == 0) {
layoutParams.height = 1;
if (layoutParams.height <= 0) {
layoutParams.height = 100;
}
float scaleX = (float) windowView.getMeasuredWidth() / layoutParams.width;