fix: absorb libcosmic theme-v2 API (nav_context_menu, app_popup LiveSettings)
Leyoda 2026 – GPLv3
This commit is contained in:
parent
2a74748083
commit
fd4a2ba610
4 changed files with 11 additions and 9 deletions
|
|
@ -2817,7 +2817,7 @@ impl Application for App {
|
|||
.on_middle_press(|entity| {
|
||||
cosmic::Action::App(Message::NavMenuAction(NavMenuAction::OpenInNewTab(entity)))
|
||||
})
|
||||
.context_menu(self.nav_context_menu(self.nav_bar_context_id))
|
||||
.context_menu(self.nav_context_menu())
|
||||
.close_icon(icon::from_name("media-eject-symbolic").size(16).icon())
|
||||
.into_container();
|
||||
|
||||
|
|
@ -2832,8 +2832,8 @@ impl Application for App {
|
|||
|
||||
fn nav_context_menu(
|
||||
&self,
|
||||
entity: widget::nav_bar::Id,
|
||||
) -> Option<Vec<widget::menu::Tree<cosmic::Action<Self::Message>>>> {
|
||||
let entity = self.nav_bar_context_id;
|
||||
let favorite_index_opt = self.nav_model.data::<FavoriteIndex>(entity);
|
||||
let location_opt = self.nav_model.data::<Location>(entity);
|
||||
|
||||
|
|
@ -4885,6 +4885,7 @@ impl Application for App {
|
|||
commands.push(self.update(Message::CheckClipboard));
|
||||
commands.push(self.update(Message::Surface(
|
||||
cosmic::surface::action::app_popup(
|
||||
|_: &Self| cosmic::surface::action::LiveSettings::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