1 // This file was generated by gir (https://github.com/gtk-rs/gir) 2 // from gir-files (https://github.com/gtk-rs/gir-files) 3 // DO NOT EDIT 4 5 use crate::ActionGroup; 6 use crate::ActionMap; 7 use glib::translate::*; 8 use std::fmt; 9 10 glib::wrapper! { 11 #[doc(alias = "GSimpleActionGroup")] 12 pub struct SimpleActionGroup(Object<ffi::GSimpleActionGroup, ffi::GSimpleActionGroupClass>) @implements ActionGroup, ActionMap; 13 14 match fn { 15 type_ => || ffi::g_simple_action_group_get_type(), 16 } 17 } 18 19 impl SimpleActionGroup { 20 #[doc(alias = "g_simple_action_group_new")] new() -> SimpleActionGroup21 pub fn new() -> SimpleActionGroup { 22 unsafe { from_glib_full(ffi::g_simple_action_group_new()) } 23 } 24 } 25 26 impl Default for SimpleActionGroup { default() -> Self27 fn default() -> Self { 28 Self::new() 29 } 30 } 31 32 pub const NONE_SIMPLE_ACTION_GROUP: Option<&SimpleActionGroup> = None; 33 34 impl fmt::Display for SimpleActionGroup { fmt(&self, f: &mut fmt::Formatter) -> fmt::Result35 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { 36 f.write_str("SimpleActionGroup") 37 } 38 } 39