forge
Explore
Log in

Don't you dare go Hollow

Clamp animated window size

Browse files at this commit

1b496ee21fab09fee819a5baf685dfd594690d23Ivan MolodetskikhParent: bde46da
src/layout/tile.rsmodified+2 -0
@@ -351,7 +351,9 @@ impl<W: LayoutElement> Tile<W> {
351 let size_from = resize.size_from;351 let size_from = resize.size_from;
352 352
353 size.w = (size_from.w as f64 + (size.w - size_from.w) as f64 * val).round() as i32;353 size.w = (size_from.w as f64 + (size.w - size_from.w) as f64 * val).round() as i32;
354+ size.w = max(1, size.w);
354 size.h = (size_from.h as f64 + (size.h - size_from.h) as f64 * val).round() as i32;355 size.h = (size_from.h as f64 + (size.h - size_from.h) as f64 * val).round() as i32;
356+ size.h = max(1, size.h);
355 }357 }
356 358
357 size359 size