cleanup
This commit is contained in:
parent
6c46fb03a6
commit
5a4a802751
1 changed files with 0 additions and 19 deletions
|
|
@ -1,19 +0,0 @@
|
||||||
use gio::DesktopAppInfo;
|
|
||||||
use glib::prelude::*;
|
|
||||||
use glib::subclass;
|
|
||||||
use glib::subclass::prelude::*;
|
|
||||||
|
|
||||||
#[derive(Clone, Debug, PartialEq, Eq, glib::GBoxed)]
|
|
||||||
#[gboxed(type_name = "MyBoxed")]
|
|
||||||
struct MyBoxed(DesktopAppInfo);
|
|
||||||
|
|
||||||
pub fn main() {
|
|
||||||
let appinfo = DesktopAppInfo::new("firefox.desktop").expect("failed to get app info");
|
|
||||||
assert!(MyBoxed::static_type().is_valid());
|
|
||||||
|
|
||||||
let b = MyBoxed(appinfo);
|
|
||||||
let v = b.to_value();
|
|
||||||
let b2 = v.get::<&MyBoxed>().unwrap();
|
|
||||||
assert_eq!(&b, b2);
|
|
||||||
dbg!(&b2.0.filename());
|
|
||||||
}
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue