Update gtk and libadwaita

This commit is contained in:
Elias Projahn 2024-04-01 18:47:44 +02:00
parent 783d548bc2
commit 6b7c925fac
4 changed files with 79 additions and 170 deletions

View file

@ -2,7 +2,11 @@ use crate::{
library::LibraryQuery,
search_tag::{MusicusSearchTag, Tag},
};
use adw::{gdk, gio, glib, glib::clone, glib::subclass::Signal, prelude::*, subclass::prelude::*};
use adw::{prelude::*, subclass::prelude::*};
use gtk::{
gdk, gio,
glib::{self, clone, subclass::Signal, Propagation},
};
use once_cell::sync::Lazy;
use std::{cell::RefCell, time::Duration};
@ -45,9 +49,9 @@ mod imp {
) {
Some(obj) => {
obj.reset();
true
Propagation::Stop
}
None => false,
None => Propagation::Proceed,
}))
.build(),
);
@ -150,7 +154,7 @@ impl MusicusSearchEntry {
imp.clear_icon.set_visible(true);
imp.text.set_text("");
let tag = MusicusSearchTag::new(tag);
tag.connect_remove(clone!(@weak self as self_ => move |tag| {

View file

@ -117,7 +117,7 @@ glib::wrapper! {
#[gtk::template_callbacks]
impl MusicusWindow {
pub fn new<P: glib::IsA<gtk::Application>>(application: &P) -> Self {
pub fn new<P: IsA<gtk::Application>>(application: &P) -> Self {
glib::Object::builder()
.property("application", application)
.build()