chore: update libcosmic (#1713)
- [x] I have disclosed use of any AI generated code in my commit messages. - If you are using an LLM, and do not fully understand the changes it is making to the code base, do not create a PR. - In our experience, AI generated code often results in overly complex code that lacks enough context for a proper fix or feature inclusion. This results in considerably longer code reviews. Due to this, AI authored or partially authored PRs may be closed without comment. - [x] I understand these changes in full and will be able to respond to review comments. - [x] My change is accurately described in the commit message. - [x] My contribution is tested and working as described. - [x] I have read the [Developer Certificate of Origin](https://developercertificate.org/) and certify my contribution under its conditions.
This commit is contained in:
commit
fab53e54d6
6 changed files with 242 additions and 173 deletions
|
|
@ -1790,11 +1790,28 @@ impl Application for App {
|
|||
SctkPopupSettings, SctkPositioner,
|
||||
};
|
||||
use cosmic::iced::Rectangle;
|
||||
use cosmic::widget::menu::StyleSheet as _;
|
||||
|
||||
let window_id = window::Id::unique();
|
||||
self.context_menu_window = Some(window_id);
|
||||
let autosize_id = widget::Id::unique();
|
||||
let t = self.core.system_theme();
|
||||
let styling = t.appearance(
|
||||
&cosmic::theme::menu_bar::MenuBarStyle::Default,
|
||||
false,
|
||||
);
|
||||
let rad = styling.menu_border_radius;
|
||||
commands.push(self.update(Message::Surface(
|
||||
cosmic::surface::action::app_popup(
|
||||
move |_| cosmic::surface::action::LiveSettings {
|
||||
corners: Some(iced::runtime::platform_specific::wayland::CornerRadius {
|
||||
top_left: rad[0] as u32,
|
||||
top_right: rad[1] as u32,
|
||||
bottom_left: rad[2] as u32,
|
||||
bottom_right: rad[3] as u32,
|
||||
}),
|
||||
..Default::default()
|
||||
},
|
||||
move |app: &mut Self| -> SctkPopupSettings {
|
||||
let anchor_rect = Rectangle {
|
||||
x: point.x as i32,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue