[−][src]Macro qmetaobject::qt_method
This macro can be used to declare a method which will become a meta method.
Inside you can either declare the method signature, or write the full method.
Can be used within a struct that derives from QObject or QGadget
#[derive(QObject)] struct Foo { base : qt_base_class!(trait QObject), defined_method : qt_method!(fn defined_method(&self, foo : u32) -> u32 { println!("contents goes here."); return 42; }), outofline_method : qt_method!(fn(&self, foo : u32)-> u32), } impl Foo { fn outofline_method(&mut self, foo : u32) -> u32 { println!("Or here."); return 69; } }