generate missing functions
This commit is contained in:
parent
a4a97fc1c9
commit
f4d62f8f64
|
@ -75,6 +75,20 @@ manual = [
|
||||||
"Pango.EllipsizeMode",
|
"Pango.EllipsizeMode",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
[[object]]
|
||||||
|
name = "Handy.*"
|
||||||
|
status = "generate"
|
||||||
|
[[object.function]]
|
||||||
|
name = "init"
|
||||||
|
# generated manually
|
||||||
|
ignore = true
|
||||||
|
[[object.function]]
|
||||||
|
name = "string_utf8_truncate"
|
||||||
|
ignore = true
|
||||||
|
[[object.function]]
|
||||||
|
name = "string_utf8_len"
|
||||||
|
ignore = true
|
||||||
|
|
||||||
[[object]]
|
[[object]]
|
||||||
name = "Handy.ActionRow"
|
name = "Handy.ActionRow"
|
||||||
status = "generate"
|
status = "generate"
|
||||||
|
|
36
libhandy/src/auto/functions.rs
Normal file
36
libhandy/src/auto/functions.rs
Normal file
|
@ -0,0 +1,36 @@
|
||||||
|
// This file was generated by gir (https://github.com/gtk-rs/gir)
|
||||||
|
// from gir-files (https://github.com/gtk-rs/gir-files)
|
||||||
|
// DO NOT EDIT
|
||||||
|
|
||||||
|
#[cfg(any(feature = "v0_0_11", feature = "dox"))]
|
||||||
|
use glib::object::IsA;
|
||||||
|
use glib::translate::*;
|
||||||
|
#[cfg(any(feature = "v0_0_11", feature = "dox"))]
|
||||||
|
use gtk;
|
||||||
|
use handy_sys;
|
||||||
|
|
||||||
|
#[cfg(any(feature = "v0_0_11", feature = "dox"))]
|
||||||
|
pub fn ease_out_cubic(t: f64) -> f64 {
|
||||||
|
assert_initialized_main_thread!();
|
||||||
|
unsafe { handy_sys::hdy_ease_out_cubic(t) }
|
||||||
|
}
|
||||||
|
|
||||||
|
//#[cfg(any(feature = "v0_0_6", feature = "dox"))]
|
||||||
|
//pub fn enum_value_row_name(value: /*Ignored*/&EnumValueObject, user_data: /*Unimplemented*/Option<Fundamental: Pointer>) -> Option<GString> {
|
||||||
|
// unsafe { TODO: call handy_sys:hdy_enum_value_row_name() }
|
||||||
|
//}
|
||||||
|
|
||||||
|
#[cfg(any(feature = "v0_0_11", feature = "dox"))]
|
||||||
|
pub fn get_enable_animations<P: IsA<gtk::Widget>>(widget: &P) -> bool {
|
||||||
|
assert_initialized_main_thread!();
|
||||||
|
unsafe {
|
||||||
|
from_glib(handy_sys::hdy_get_enable_animations(
|
||||||
|
widget.as_ref().to_glib_none().0,
|
||||||
|
))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//#[cfg(any(feature = "v0_0_6", feature = "dox"))]
|
||||||
|
//pub fn list_box_separator_header<P: IsA<gtk::ListBoxRow>, Q: IsA<gtk::ListBoxRow>>(row: &P, before: Option<&Q>, unused_user_data: /*Unimplemented*/Option<Fundamental: Pointer>) {
|
||||||
|
// unsafe { TODO: call handy_sys:hdy_list_box_separator_header() }
|
||||||
|
//}
|
|
@ -191,6 +191,8 @@ pub use self::enums::PaginatorIndicatorStyle;
|
||||||
pub use self::enums::SqueezerTransitionType;
|
pub use self::enums::SqueezerTransitionType;
|
||||||
pub use self::enums::ViewSwitcherPolicy;
|
pub use self::enums::ViewSwitcherPolicy;
|
||||||
|
|
||||||
|
pub mod functions;
|
||||||
|
|
||||||
#[doc(hidden)]
|
#[doc(hidden)]
|
||||||
pub mod traits {
|
pub mod traits {
|
||||||
pub use super::ActionRowExt;
|
pub use super::ActionRowExt;
|
||||||
|
|
13
libhandy/src/functions.rs
Normal file
13
libhandy/src/functions.rs
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
use glib::translate::*;
|
||||||
|
use handy_sys;
|
||||||
|
use std::ptr;
|
||||||
|
|
||||||
|
pub fn init() -> Result<(), glib::BoolError> {
|
||||||
|
unsafe {
|
||||||
|
if from_glib(handy_sys::hdy_init(ptr::null_mut(), ptr::null_mut())) {
|
||||||
|
Ok(())
|
||||||
|
} else {
|
||||||
|
Err(glib_bool_error!("Failed to initialize Handy"))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -39,6 +39,8 @@ macro_rules! skip_assert_initialized {
|
||||||
}
|
}
|
||||||
|
|
||||||
pub use glib::Error;
|
pub use glib::Error;
|
||||||
|
mod functions;
|
||||||
|
pub use functions::*;
|
||||||
pub mod prelude;
|
pub mod prelude;
|
||||||
pub use prelude::*;
|
pub use prelude::*;
|
||||||
#[cfg_attr(feature = "cargo-clippy", allow(too_many_arguments))]
|
#[cfg_attr(feature = "cargo-clippy", allow(too_many_arguments))]
|
||||||
|
|
Loading…
Reference in a new issue