add missing interfaces to manual bindings
this will allow our generated objects to implement these interfaces
This commit is contained in:
parent
568a09eda8
commit
a4a97fc1c9
|
@ -10,7 +10,7 @@ deprecate_by_min_version = true
|
|||
# with this option enabled, versions for gir and gir-files saved only to one file to minimize noise
|
||||
single_version_file = true
|
||||
|
||||
external_libraries = [
|
||||
external_libraries = [
|
||||
"GLib",
|
||||
"GObject",
|
||||
"Gdk",
|
||||
|
@ -37,16 +37,19 @@ generate = [
|
|||
|
||||
manual = [
|
||||
"GLib.String",
|
||||
"GLib.Variant",
|
||||
"GObject.Object",
|
||||
"GObject.Value",
|
||||
"Gdk.Event",
|
||||
"Gdk.EventMask",
|
||||
"Gio.ListModel",
|
||||
"Gtk.Actionable",
|
||||
"Gtk.Adjustment",
|
||||
"Gtk.Align",
|
||||
"Gtk.BaselinePosition",
|
||||
"Gtk.Bin",
|
||||
"Gtk.Box",
|
||||
"Gtk.Buildable",
|
||||
"Gtk.Button",
|
||||
"Gtk.Container",
|
||||
"Gtk.CornerType",
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
// DO NOT EDIT
|
||||
|
||||
use gdk;
|
||||
use glib;
|
||||
use glib::object::Cast;
|
||||
use glib::object::IsA;
|
||||
#[cfg(any(feature = "v0_0_6", feature = "dox"))]
|
||||
|
@ -26,7 +27,7 @@ use std::mem::transmute;
|
|||
use PreferencesRow;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct ActionRow(Object<handy_sys::HdyActionRow, handy_sys::HdyActionRowClass, ActionRowClass>) @extends PreferencesRow, gtk::ListBoxRow, gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct ActionRow(Object<handy_sys::HdyActionRow, handy_sys::HdyActionRowClass, ActionRowClass>) @extends PreferencesRow, gtk::ListBoxRow, gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable, gtk::Actionable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_action_row_get_type(),
|
||||
|
@ -123,6 +124,8 @@ pub struct ActionRowBuilder {
|
|||
vexpand_set: Option<bool>,
|
||||
visible: Option<bool>,
|
||||
width_request: Option<i32>,
|
||||
action_name: Option<String>,
|
||||
action_target: Option<glib::Variant>,
|
||||
}
|
||||
|
||||
impl ActionRowBuilder {
|
||||
|
@ -348,6 +351,12 @@ impl ActionRowBuilder {
|
|||
if let Some(ref width_request) = self.width_request {
|
||||
properties.push(("width-request", width_request));
|
||||
}
|
||||
if let Some(ref action_name) = self.action_name {
|
||||
properties.push(("action-name", action_name));
|
||||
}
|
||||
if let Some(ref action_target) = self.action_target {
|
||||
properties.push(("action-target", action_target));
|
||||
}
|
||||
let ret = glib::Object::new(ActionRow::static_type(), &properties)
|
||||
.expect("object new")
|
||||
.downcast::<ActionRow>()
|
||||
|
@ -606,6 +615,16 @@ impl ActionRowBuilder {
|
|||
self.width_request = Some(width_request);
|
||||
self
|
||||
}
|
||||
|
||||
pub fn action_name(mut self, action_name: &str) -> Self {
|
||||
self.action_name = Some(action_name.to_string());
|
||||
self
|
||||
}
|
||||
|
||||
pub fn action_target(mut self, action_target: &glib::Variant) -> Self {
|
||||
self.action_target = Some(action_target.clone());
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
pub const NONE_ACTION_ROW: Option<&ActionRow> = None;
|
||||
|
|
|
@ -19,7 +19,7 @@ use std::mem::transmute;
|
|||
use ArrowsDirection;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct Arrows(Object<handy_sys::HdyArrows, handy_sys::HdyArrowsClass, ArrowsClass>) @extends gtk::DrawingArea, gtk::Widget;
|
||||
pub struct Arrows(Object<handy_sys::HdyArrows, handy_sys::HdyArrowsClass, ArrowsClass>) @extends gtk::DrawingArea, gtk::Widget, @implements gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_arrows_get_type(),
|
||||
|
|
|
@ -18,7 +18,7 @@ use std::fmt;
|
|||
use std::mem::transmute;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct Column(Object<handy_sys::HdyColumn, handy_sys::HdyColumnClass, ColumnClass>) @extends gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct Column(Object<handy_sys::HdyColumn, handy_sys::HdyColumnClass, ColumnClass>) @extends gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_column_get_type(),
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
use gdk;
|
||||
#[cfg(any(feature = "v0_0_6", feature = "dox"))]
|
||||
use gio;
|
||||
#[cfg(any(feature = "v0_0_6", feature = "dox"))]
|
||||
use glib;
|
||||
use glib::object::Cast;
|
||||
use glib::object::IsA;
|
||||
|
@ -29,7 +28,7 @@ use ActionRow;
|
|||
use PreferencesRow;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct ComboRow(Object<handy_sys::HdyComboRow, handy_sys::HdyComboRowClass, ComboRowClass>) @extends ActionRow, PreferencesRow, gtk::ListBoxRow, gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct ComboRow(Object<handy_sys::HdyComboRow, handy_sys::HdyComboRowClass, ComboRowClass>) @extends ActionRow, PreferencesRow, gtk::ListBoxRow, gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable, gtk::Actionable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_combo_row_get_type(),
|
||||
|
@ -130,6 +129,8 @@ pub struct ComboRowBuilder {
|
|||
vexpand_set: Option<bool>,
|
||||
visible: Option<bool>,
|
||||
width_request: Option<i32>,
|
||||
action_name: Option<String>,
|
||||
action_target: Option<glib::Variant>,
|
||||
}
|
||||
|
||||
impl ComboRowBuilder {
|
||||
|
@ -367,6 +368,12 @@ impl ComboRowBuilder {
|
|||
if let Some(ref width_request) = self.width_request {
|
||||
properties.push(("width-request", width_request));
|
||||
}
|
||||
if let Some(ref action_name) = self.action_name {
|
||||
properties.push(("action-name", action_name));
|
||||
}
|
||||
if let Some(ref action_target) = self.action_target {
|
||||
properties.push(("action-target", action_target));
|
||||
}
|
||||
let ret = glib::Object::new(ComboRow::static_type(), &properties)
|
||||
.expect("object new")
|
||||
.downcast::<ComboRow>()
|
||||
|
@ -637,6 +644,16 @@ impl ComboRowBuilder {
|
|||
self.width_request = Some(width_request);
|
||||
self
|
||||
}
|
||||
|
||||
pub fn action_name(mut self, action_name: &str) -> Self {
|
||||
self.action_name = Some(action_name.to_string());
|
||||
self
|
||||
}
|
||||
|
||||
pub fn action_target(mut self, action_target: &glib::Variant) -> Self {
|
||||
self.action_target = Some(action_target.clone());
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
pub const NONE_COMBO_ROW: Option<&ComboRow> = None;
|
||||
|
|
|
@ -23,7 +23,7 @@ use std::fmt;
|
|||
use std::mem::transmute;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct Dialer(Object<handy_sys::HdyDialer, handy_sys::HdyDialerClass, DialerClass>) @extends gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct Dialer(Object<handy_sys::HdyDialer, handy_sys::HdyDialerClass, DialerClass>) @extends gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_dialer_get_type(),
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
// DO NOT EDIT
|
||||
|
||||
use gdk;
|
||||
use glib;
|
||||
use glib::object::Cast;
|
||||
use glib::object::IsA;
|
||||
use glib::signal::connect_raw;
|
||||
|
@ -21,7 +22,7 @@ use std::fmt;
|
|||
use std::mem::transmute;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct DialerButton(Object<handy_sys::HdyDialerButton, handy_sys::HdyDialerButtonClass, DialerButtonClass>) @extends gtk::Button, gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct DialerButton(Object<handy_sys::HdyDialerButton, handy_sys::HdyDialerButtonClass, DialerButtonClass>) @extends gtk::Button, gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable, gtk::Actionable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_dialer_button_get_type(),
|
||||
|
@ -115,6 +116,8 @@ pub struct DialerButtonBuilder {
|
|||
vexpand_set: Option<bool>,
|
||||
visible: Option<bool>,
|
||||
width_request: Option<i32>,
|
||||
action_name: Option<String>,
|
||||
action_target: Option<glib::Variant>,
|
||||
}
|
||||
|
||||
impl DialerButtonBuilder {
|
||||
|
@ -343,6 +346,12 @@ impl DialerButtonBuilder {
|
|||
if let Some(ref width_request) = self.width_request {
|
||||
properties.push(("width-request", width_request));
|
||||
}
|
||||
if let Some(ref action_name) = self.action_name {
|
||||
properties.push(("action-name", action_name));
|
||||
}
|
||||
if let Some(ref action_target) = self.action_target {
|
||||
properties.push(("action-target", action_target));
|
||||
}
|
||||
let ret = glib::Object::new(DialerButton::static_type(), &properties)
|
||||
.expect("object new")
|
||||
.downcast::<DialerButton>()
|
||||
|
@ -614,6 +623,16 @@ impl DialerButtonBuilder {
|
|||
self.width_request = Some(width_request);
|
||||
self
|
||||
}
|
||||
|
||||
pub fn action_name(mut self, action_name: &str) -> Self {
|
||||
self.action_name = Some(action_name.to_string());
|
||||
self
|
||||
}
|
||||
|
||||
pub fn action_target(mut self, action_target: &glib::Variant) -> Self {
|
||||
self.action_target = Some(action_target.clone());
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
pub const NONE_DIALER_BUTTON: Option<&DialerButton> = None;
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
// DO NOT EDIT
|
||||
|
||||
use gdk;
|
||||
use glib;
|
||||
use glib::object::Cast;
|
||||
use glib::object::IsA;
|
||||
use glib::signal::connect_raw;
|
||||
|
@ -19,7 +20,7 @@ use std::mem::transmute;
|
|||
use DialerButton;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct DialerCycleButton(Object<handy_sys::HdyDialerCycleButton, handy_sys::HdyDialerCycleButtonClass, DialerCycleButtonClass>) @extends DialerButton, gtk::Button, gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct DialerCycleButton(Object<handy_sys::HdyDialerCycleButton, handy_sys::HdyDialerCycleButtonClass, DialerCycleButtonClass>) @extends DialerButton, gtk::Button, gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable, gtk::Actionable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_dialer_cycle_button_get_type(),
|
||||
|
@ -116,6 +117,8 @@ pub struct DialerCycleButtonBuilder {
|
|||
vexpand_set: Option<bool>,
|
||||
visible: Option<bool>,
|
||||
width_request: Option<i32>,
|
||||
action_name: Option<String>,
|
||||
action_target: Option<glib::Variant>,
|
||||
}
|
||||
|
||||
impl DialerCycleButtonBuilder {
|
||||
|
@ -347,6 +350,12 @@ impl DialerCycleButtonBuilder {
|
|||
if let Some(ref width_request) = self.width_request {
|
||||
properties.push(("width-request", width_request));
|
||||
}
|
||||
if let Some(ref action_name) = self.action_name {
|
||||
properties.push(("action-name", action_name));
|
||||
}
|
||||
if let Some(ref action_target) = self.action_target {
|
||||
properties.push(("action-target", action_target));
|
||||
}
|
||||
let ret = glib::Object::new(DialerCycleButton::static_type(), &properties)
|
||||
.expect("object new")
|
||||
.downcast::<DialerCycleButton>()
|
||||
|
@ -623,6 +632,16 @@ impl DialerCycleButtonBuilder {
|
|||
self.width_request = Some(width_request);
|
||||
self
|
||||
}
|
||||
|
||||
pub fn action_name(mut self, action_name: &str) -> Self {
|
||||
self.action_name = Some(action_name.to_string());
|
||||
self
|
||||
}
|
||||
|
||||
pub fn action_target(mut self, action_target: &glib::Variant) -> Self {
|
||||
self.action_target = Some(action_target.clone());
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
pub const NONE_DIALER_CYCLE_BUTTON: Option<&DialerCycleButton> = None;
|
||||
|
|
|
@ -21,7 +21,7 @@ use std::fmt;
|
|||
use std::mem::transmute;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct Dialog(Object<handy_sys::HdyDialog, handy_sys::HdyDialogClass, DialogClass>) @extends gtk::Dialog, gtk::Window, gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct Dialog(Object<handy_sys::HdyDialog, handy_sys::HdyDialogClass, DialogClass>) @extends gtk::Dialog, gtk::Window, gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_dialog_get_type(),
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
// DO NOT EDIT
|
||||
|
||||
use gdk;
|
||||
use glib;
|
||||
use glib::object::Cast;
|
||||
use glib::object::IsA;
|
||||
use glib::signal::connect_raw;
|
||||
|
@ -22,7 +23,7 @@ use ActionRow;
|
|||
use PreferencesRow;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct ExpanderRow(Object<handy_sys::HdyExpanderRow, handy_sys::HdyExpanderRowClass, ExpanderRowClass>) @extends ActionRow, PreferencesRow, gtk::ListBoxRow, gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct ExpanderRow(Object<handy_sys::HdyExpanderRow, handy_sys::HdyExpanderRowClass, ExpanderRowClass>) @extends ActionRow, PreferencesRow, gtk::ListBoxRow, gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable, gtk::Actionable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_expander_row_get_type(),
|
||||
|
@ -122,6 +123,8 @@ pub struct ExpanderRowBuilder {
|
|||
vexpand_set: Option<bool>,
|
||||
visible: Option<bool>,
|
||||
width_request: Option<i32>,
|
||||
action_name: Option<String>,
|
||||
action_target: Option<glib::Variant>,
|
||||
}
|
||||
|
||||
impl ExpanderRowBuilder {
|
||||
|
@ -356,6 +359,12 @@ impl ExpanderRowBuilder {
|
|||
if let Some(ref width_request) = self.width_request {
|
||||
properties.push(("width-request", width_request));
|
||||
}
|
||||
if let Some(ref action_name) = self.action_name {
|
||||
properties.push(("action-name", action_name));
|
||||
}
|
||||
if let Some(ref action_target) = self.action_target {
|
||||
properties.push(("action-target", action_target));
|
||||
}
|
||||
let ret = glib::Object::new(ExpanderRow::static_type(), &properties)
|
||||
.expect("object new")
|
||||
.downcast::<ExpanderRow>()
|
||||
|
@ -629,6 +638,16 @@ impl ExpanderRowBuilder {
|
|||
self.width_request = Some(width_request);
|
||||
self
|
||||
}
|
||||
|
||||
pub fn action_name(mut self, action_name: &str) -> Self {
|
||||
self.action_name = Some(action_name.to_string());
|
||||
self
|
||||
}
|
||||
|
||||
pub fn action_target(mut self, action_target: &glib::Variant) -> Self {
|
||||
self.action_target = Some(action_target.clone());
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
pub const NONE_EXPANDER_ROW: Option<&ExpanderRow> = None;
|
||||
|
|
|
@ -23,7 +23,7 @@ use std::mem::transmute;
|
|||
use CenteringPolicy;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct HeaderBar(Object<handy_sys::HdyHeaderBar, handy_sys::HdyHeaderBarClass, HeaderBarClass>) @extends gtk::Container, gtk::Widget;
|
||||
pub struct HeaderBar(Object<handy_sys::HdyHeaderBar, handy_sys::HdyHeaderBarClass, HeaderBarClass>) @extends gtk::Container, gtk::Widget, @implements gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_header_bar_get_type(),
|
||||
|
|
|
@ -17,7 +17,7 @@ use std::fmt;
|
|||
use std::mem::transmute;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct HeaderGroup(Object<handy_sys::HdyHeaderGroup, handy_sys::HdyHeaderGroupClass, HeaderGroupClass>);
|
||||
pub struct HeaderGroup(Object<handy_sys::HdyHeaderGroup, handy_sys::HdyHeaderGroupClass, HeaderGroupClass>) @implements gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_header_group_get_type(),
|
||||
|
|
|
@ -20,7 +20,7 @@ use std::fmt;
|
|||
use std::mem::transmute;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct Keypad(Object<handy_sys::HdyKeypad, handy_sys::HdyKeypadClass, KeypadClass>) @extends gtk::Grid, gtk::Container, gtk::Widget, @implements gtk::Orientable;
|
||||
pub struct Keypad(Object<handy_sys::HdyKeypad, handy_sys::HdyKeypadClass, KeypadClass>) @extends gtk::Grid, gtk::Container, gtk::Widget, @implements gtk::Buildable, gtk::Orientable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_keypad_get_type(),
|
||||
|
|
|
@ -27,7 +27,7 @@ use LeafletTransitionType;
|
|||
use Swipeable;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct Leaflet(Object<handy_sys::HdyLeaflet, handy_sys::HdyLeafletClass, LeafletClass>) @extends gtk::Container, gtk::Widget, @implements gtk::Orientable, Swipeable;
|
||||
pub struct Leaflet(Object<handy_sys::HdyLeaflet, handy_sys::HdyLeafletClass, LeafletClass>) @extends gtk::Container, gtk::Widget, @implements gtk::Buildable, gtk::Orientable, Swipeable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_leaflet_get_type(),
|
||||
|
|
|
@ -28,7 +28,7 @@ use PaginatorIndicatorStyle;
|
|||
use Swipeable;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct Paginator(Object<handy_sys::HdyPaginator, handy_sys::HdyPaginatorClass, PaginatorClass>) @extends gtk::EventBox, gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Orientable, Swipeable;
|
||||
pub struct Paginator(Object<handy_sys::HdyPaginator, handy_sys::HdyPaginatorClass, PaginatorClass>) @extends gtk::EventBox, gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable, gtk::Orientable, Swipeable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_paginator_get_type(),
|
||||
|
|
|
@ -25,7 +25,7 @@ use std::fmt;
|
|||
use std::mem::transmute;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct PreferencesGroup(Object<handy_sys::HdyPreferencesGroup, handy_sys::HdyPreferencesGroupClass, PreferencesGroupClass>) @extends gtk::Box, gtk::Container, gtk::Widget, @implements gtk::Orientable;
|
||||
pub struct PreferencesGroup(Object<handy_sys::HdyPreferencesGroup, handy_sys::HdyPreferencesGroupClass, PreferencesGroupClass>) @extends gtk::Box, gtk::Container, gtk::Widget, @implements gtk::Buildable, gtk::Orientable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_preferences_group_get_type(),
|
||||
|
|
|
@ -25,7 +25,7 @@ use std::fmt;
|
|||
use std::mem::transmute;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct PreferencesPage(Object<handy_sys::HdyPreferencesPage, handy_sys::HdyPreferencesPageClass, PreferencesPageClass>) @extends gtk::ScrolledWindow, gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct PreferencesPage(Object<handy_sys::HdyPreferencesPage, handy_sys::HdyPreferencesPageClass, PreferencesPageClass>) @extends gtk::ScrolledWindow, gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_preferences_page_get_type(),
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
// DO NOT EDIT
|
||||
|
||||
use gdk;
|
||||
use glib;
|
||||
use glib::object::Cast;
|
||||
use glib::object::IsA;
|
||||
#[cfg(any(feature = "v0_0_10", feature = "dox"))]
|
||||
|
@ -25,7 +26,7 @@ use std::fmt;
|
|||
use std::mem::transmute;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct PreferencesRow(Object<handy_sys::HdyPreferencesRow, handy_sys::HdyPreferencesRowClass, PreferencesRowClass>) @extends gtk::ListBoxRow, gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct PreferencesRow(Object<handy_sys::HdyPreferencesRow, handy_sys::HdyPreferencesRowClass, PreferencesRowClass>) @extends gtk::ListBoxRow, gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable, gtk::Actionable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_preferences_row_get_type(),
|
||||
|
@ -116,6 +117,8 @@ pub struct PreferencesRowBuilder {
|
|||
vexpand_set: Option<bool>,
|
||||
visible: Option<bool>,
|
||||
width_request: Option<i32>,
|
||||
action_name: Option<String>,
|
||||
action_target: Option<glib::Variant>,
|
||||
}
|
||||
|
||||
impl PreferencesRowBuilder {
|
||||
|
@ -323,6 +326,12 @@ impl PreferencesRowBuilder {
|
|||
if let Some(ref width_request) = self.width_request {
|
||||
properties.push(("width-request", width_request));
|
||||
}
|
||||
if let Some(ref action_name) = self.action_name {
|
||||
properties.push(("action-name", action_name));
|
||||
}
|
||||
if let Some(ref action_target) = self.action_target {
|
||||
properties.push(("action-target", action_target));
|
||||
}
|
||||
let ret = glib::Object::new(PreferencesRow::static_type(), &properties)
|
||||
.expect("object new")
|
||||
.downcast::<PreferencesRow>()
|
||||
|
@ -563,6 +572,16 @@ impl PreferencesRowBuilder {
|
|||
self.width_request = Some(width_request);
|
||||
self
|
||||
}
|
||||
|
||||
pub fn action_name(mut self, action_name: &str) -> Self {
|
||||
self.action_name = Some(action_name.to_string());
|
||||
self
|
||||
}
|
||||
|
||||
pub fn action_target(mut self, action_target: &glib::Variant) -> Self {
|
||||
self.action_target = Some(action_target.clone());
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
pub const NONE_PREFERENCES_ROW: Option<&PreferencesRow> = None;
|
||||
|
|
|
@ -8,7 +8,7 @@ use handy_sys;
|
|||
use std::fmt;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct PreferencesWindow(Object<handy_sys::HdyPreferencesWindow, handy_sys::HdyPreferencesWindowClass, PreferencesWindowClass>) @extends gtk::Window, gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct PreferencesWindow(Object<handy_sys::HdyPreferencesWindow, handy_sys::HdyPreferencesWindowClass, PreferencesWindowClass>) @extends gtk::Window, gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_preferences_window_get_type(),
|
||||
|
|
|
@ -20,7 +20,7 @@ use std::fmt;
|
|||
use std::mem::transmute;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct SearchBar(Object<handy_sys::HdySearchBar, handy_sys::HdySearchBarClass, SearchBarClass>) @extends gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct SearchBar(Object<handy_sys::HdySearchBar, handy_sys::HdySearchBarClass, SearchBarClass>) @extends gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_search_bar_get_type(),
|
||||
|
|
|
@ -21,7 +21,7 @@ use std::mem::transmute;
|
|||
use SqueezerTransitionType;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct Squeezer(Object<handy_sys::HdySqueezer, handy_sys::HdySqueezerClass, SqueezerClass>) @extends gtk::Container, gtk::Widget, @implements gtk::Orientable;
|
||||
pub struct Squeezer(Object<handy_sys::HdySqueezer, handy_sys::HdySqueezerClass, SqueezerClass>) @extends gtk::Container, gtk::Widget, @implements gtk::Buildable, gtk::Orientable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_squeezer_get_type(),
|
||||
|
|
|
@ -4,13 +4,14 @@
|
|||
|
||||
use glib::object::IsA;
|
||||
use glib::translate::*;
|
||||
use gtk;
|
||||
use handy_sys;
|
||||
use std::fmt;
|
||||
#[cfg(any(feature = "v0_0_12", feature = "dox"))]
|
||||
use Swipeable;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct SwipeGroup(Object<handy_sys::HdySwipeGroup, handy_sys::HdySwipeGroupClass, SwipeGroupClass>);
|
||||
pub struct SwipeGroup(Object<handy_sys::HdySwipeGroup, handy_sys::HdySwipeGroupClass, SwipeGroupClass>) @implements gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_swipe_group_get_type(),
|
||||
|
|
|
@ -23,7 +23,7 @@ use std::fmt;
|
|||
use std::mem::transmute;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct Swipeable(Interface<handy_sys::HdySwipeable>) @requires gtk::Widget;
|
||||
pub struct Swipeable(Interface<handy_sys::HdySwipeable>) @requires gtk::Widget, gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_swipeable_get_type(),
|
||||
|
|
|
@ -18,7 +18,7 @@ use std::fmt;
|
|||
use std::mem::transmute;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct TitleBar(Object<handy_sys::HdyTitleBar, handy_sys::HdyTitleBarClass, TitleBarClass>) @extends gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct TitleBar(Object<handy_sys::HdyTitleBar, handy_sys::HdyTitleBarClass, TitleBarClass>) @extends gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_title_bar_get_type(),
|
||||
|
|
|
@ -27,7 +27,7 @@ use std::mem::transmute;
|
|||
use ViewSwitcherPolicy;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct ViewSwitcher(Object<handy_sys::HdyViewSwitcher, handy_sys::HdyViewSwitcherClass, ViewSwitcherClass>) @extends gtk::Box, gtk::Container, gtk::Widget, @implements gtk::Orientable;
|
||||
pub struct ViewSwitcher(Object<handy_sys::HdyViewSwitcher, handy_sys::HdyViewSwitcherClass, ViewSwitcherClass>) @extends gtk::Box, gtk::Container, gtk::Widget, @implements gtk::Buildable, gtk::Orientable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_view_switcher_get_type(),
|
||||
|
|
|
@ -25,7 +25,7 @@ use std::mem::transmute;
|
|||
use ViewSwitcherPolicy;
|
||||
|
||||
glib_wrapper! {
|
||||
pub struct ViewSwitcherBar(Object<handy_sys::HdyViewSwitcherBar, handy_sys::HdyViewSwitcherBarClass, ViewSwitcherBarClass>) @extends gtk::Bin, gtk::Container, gtk::Widget;
|
||||
pub struct ViewSwitcherBar(Object<handy_sys::HdyViewSwitcherBar, handy_sys::HdyViewSwitcherBarClass, ViewSwitcherBarClass>) @extends gtk::Bin, gtk::Container, gtk::Widget, @implements gtk::Buildable;
|
||||
|
||||
match fn {
|
||||
get_type => || handy_sys::hdy_view_switcher_bar_get_type(),
|
||||
|
|
Loading…
Reference in a new issue