From d31c686e9ae700a9d2f1f02e6ae165e9ab5fbc1b Mon Sep 17 00:00:00 2001 From: Ashley Wulber Date: Tue, 27 Dec 2022 14:34:38 -0500 Subject: [PATCH] fix: limits on popup size and shrink popup container --- iced | 2 +- src/applet/mod.rs | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/iced b/iced index 59c96d7..bed36f6 160000 --- a/iced +++ b/iced @@ -1 +1 @@ -Subproject commit 59c96d7b7216d8231a9277ce02c333a55927732f +Subproject commit bed36f6f3be12f9839016eb30d415124428c4eba diff --git a/src/applet/mod.rs b/src/applet/mod.rs index 730c060..654a5e7 100644 --- a/src/applet/mod.rs +++ b/src/applet/mod.rs @@ -120,8 +120,8 @@ impl CosmicAppletHelper { border_color: Color::TRANSPARENT, }), )) - .width(Length::Fill) - .height(Length::Fill) + .width(Length::Shrink) + .height(Length::Shrink) .align_x(halign) .align_y(valign) } @@ -154,8 +154,8 @@ impl CosmicAppletHelper { anchor_rect: Rectangle { x: 0, y: 0, - width: width_padding.unwrap_or(APPLET_PADDING as i32) * 2 + width as i32, - height: height_padding.unwrap_or(APPLET_PADDING as i32) * 2 + height as i32, + width: width_padding.unwrap_or(APPLET_PADDING as i32) * 2 + i32::from(width), + height: height_padding.unwrap_or(APPLET_PADDING as i32) * 2 + i32::from(height), }, reactive: true, constraint_adjustment: 15, // slide_y, slide_x, flip_x, flip_y