Bump gtk-rs to the latest release
This commit is contained in:
parent
6df9059d1a
commit
57cb722e56
|
@ -2,14 +2,14 @@
|
|||
pkg-config = "0.3.7"
|
||||
|
||||
[dependencies]
|
||||
pango-sys = "0.9.0"
|
||||
gdk = "0.11.0"
|
||||
gdk-sys = "0.9.0"
|
||||
gio = "0.7.0"
|
||||
gio-sys = "0.9.0"
|
||||
glib-sys = "0.9.0"
|
||||
gobject-sys = "0.9.0"
|
||||
gtk-sys = "0.9.0"
|
||||
pango-sys = "0.9"
|
||||
gdk = "0.12"
|
||||
gdk-sys = "0.9"
|
||||
gio = "0.8"
|
||||
gio-sys = "0.9"
|
||||
glib-sys = "0.9"
|
||||
gobject-sys = "0.9"
|
||||
gtk-sys = "0.9"
|
||||
libc = "0.2"
|
||||
|
||||
[dev-dependencies]
|
||||
|
|
|
@ -21,7 +21,7 @@ struct Compiler {
|
|||
}
|
||||
|
||||
impl Compiler {
|
||||
pub fn new() -> Result<Compiler, Box<Error>> {
|
||||
pub fn new() -> Result<Compiler, Box<dyn Error>> {
|
||||
let mut args = get_var("CC", "cc")?;
|
||||
args.push("-Wno-deprecated-declarations".to_owned());
|
||||
// For %z support in printf when using MinGW.
|
||||
|
@ -40,7 +40,7 @@ impl Compiler {
|
|||
self.args.push(arg);
|
||||
}
|
||||
|
||||
pub fn compile(&self, src: &Path, out: &Path) -> Result<(), Box<Error>> {
|
||||
pub fn compile(&self, src: &Path, out: &Path) -> Result<(), Box<dyn Error>> {
|
||||
let mut cmd = self.to_command();
|
||||
cmd.arg(src);
|
||||
cmd.arg("-o");
|
||||
|
@ -60,7 +60,7 @@ impl Compiler {
|
|||
}
|
||||
}
|
||||
|
||||
fn get_var(name: &str, default: &str) -> Result<Vec<String>, Box<Error>> {
|
||||
fn get_var(name: &str, default: &str) -> Result<Vec<String>, Box<dyn Error>> {
|
||||
match env::var(name) {
|
||||
Ok(value) => Ok(shell_words::split(&value)?),
|
||||
Err(env::VarError::NotPresent) => Ok(shell_words::split(default)?),
|
||||
|
@ -68,7 +68,7 @@ fn get_var(name: &str, default: &str) -> Result<Vec<String>, Box<Error>> {
|
|||
}
|
||||
}
|
||||
|
||||
fn pkg_config_cflags(packages: &[&str]) -> Result<Vec<String>, Box<Error>> {
|
||||
fn pkg_config_cflags(packages: &[&str]) -> Result<Vec<String>, Box<dyn Error>> {
|
||||
if packages.is_empty() {
|
||||
return Ok(Vec::new());
|
||||
}
|
||||
|
@ -194,7 +194,7 @@ fn cross_validate_layout_with_c() {
|
|||
results.expect_total_success();
|
||||
}
|
||||
|
||||
fn get_c_layout(dir: &Path, cc: &Compiler, name: &str) -> Result<Layout, Box<Error>> {
|
||||
fn get_c_layout(dir: &Path, cc: &Compiler, name: &str) -> Result<Layout, Box<dyn Error>> {
|
||||
let exe = dir.join("layout");
|
||||
let mut cc = cc.clone();
|
||||
cc.define("ABI_TYPE_NAME", name);
|
||||
|
@ -214,7 +214,7 @@ fn get_c_layout(dir: &Path, cc: &Compiler, name: &str) -> Result<Layout, Box<Err
|
|||
Ok(Layout {size, alignment})
|
||||
}
|
||||
|
||||
fn get_c_value(dir: &Path, cc: &Compiler, name: &str) -> Result<String, Box<Error>> {
|
||||
fn get_c_value(dir: &Path, cc: &Compiler, name: &str) -> Result<String, Box<dyn Error>> {
|
||||
let exe = dir.join("constant");
|
||||
let mut cc = cc.clone();
|
||||
cc.define("ABI_CONSTANT_NAME", name);
|
||||
|
|
|
@ -12,22 +12,22 @@ exclude = [
|
|||
]
|
||||
|
||||
[dependencies]
|
||||
libc = "0.2.49"
|
||||
pango = "0.7.0"
|
||||
bitflags = "1.0.4"
|
||||
lazy_static = "1.2.0"
|
||||
glib-sys = "0.9.0"
|
||||
glib = "0.8.0"
|
||||
gtk-sys = "0.9.0"
|
||||
gobject-sys = "0.9.0"
|
||||
gio = "0.7.0"
|
||||
gdk = "0.11.0"
|
||||
gio-sys = "0.9.0"
|
||||
gdk-sys = "0.9.0"
|
||||
libc = '0.2.49'
|
||||
pango = '0.8'
|
||||
bitflags = '1.0.4'
|
||||
lazy_static = '1.2.0'
|
||||
glib-sys = '0.9'
|
||||
glib = '0.9'
|
||||
gtk-sys = '0.9'
|
||||
gobject-sys = '0.9'
|
||||
gio = '0.8'
|
||||
gdk = '0.12'
|
||||
gio-sys = '0.9'
|
||||
gdk-sys = '0.9'
|
||||
|
||||
[dependencies.gtk]
|
||||
version = "0.7.0"
|
||||
features = [ "v3_24" ]
|
||||
version = '0.8'
|
||||
features = ['v3_24']
|
||||
|
||||
[dependencies.libhandy-sys]
|
||||
version = "0.3.0"
|
||||
|
|
|
@ -132,7 +132,7 @@ impl<O: IsA<Dialer>> DialerExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<u32 as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"column-spacing\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `column-spacing` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -146,7 +146,7 @@ impl<O: IsA<Dialer>> DialerExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<u32 as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"row-spacing\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `row-spacing` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -123,7 +123,7 @@ impl<O: IsA<ExpanderRow>> ExpanderRowExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"enable-expansion\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `enable-expansion` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -137,7 +137,7 @@ impl<O: IsA<ExpanderRow>> ExpanderRowExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"show-enable-switch\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `show-enable-switch` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -327,7 +327,7 @@ impl<O: IsA<HeaderBar>> HeaderBarExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<CenteringPolicy as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"centering-policy\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `centering-policy` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -341,7 +341,7 @@ impl<O: IsA<HeaderBar>> HeaderBarExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<gtk::Widget as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"custom-title\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get()
|
||||
value.get().expect("Return Value for property `custom-title` getter")
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -356,7 +356,7 @@ impl<O: IsA<HeaderBar>> HeaderBarExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"decoration-layout-set\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `decoration-layout-set` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -371,7 +371,7 @@ impl<O: IsA<HeaderBar>> HeaderBarExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"interpolate-size\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `interpolate-size` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -385,7 +385,7 @@ impl<O: IsA<HeaderBar>> HeaderBarExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<i32 as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"spacing\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `spacing` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -399,7 +399,7 @@ impl<O: IsA<HeaderBar>> HeaderBarExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<GString as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"subtitle\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get()
|
||||
value.get().expect("Return Value for property `subtitle` getter")
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -413,7 +413,7 @@ impl<O: IsA<HeaderBar>> HeaderBarExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<GString as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"title\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get()
|
||||
value.get().expect("Return Value for property `title` getter")
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -427,7 +427,7 @@ impl<O: IsA<HeaderBar>> HeaderBarExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<u32 as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"transition-duration\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `transition-duration` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -441,7 +441,7 @@ impl<O: IsA<HeaderBar>> HeaderBarExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"transition-running\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `transition-running` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -263,7 +263,7 @@ impl<O: IsA<Leaflet>> LeafletExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"folded\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `folded` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -271,7 +271,7 @@ impl<O: IsA<Leaflet>> LeafletExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"hhomogeneous-folded\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `hhomogeneous-folded` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -285,7 +285,7 @@ impl<O: IsA<Leaflet>> LeafletExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"hhomogeneous-unfolded\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `hhomogeneous-unfolded` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -299,7 +299,7 @@ impl<O: IsA<Leaflet>> LeafletExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"vhomogeneous-folded\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `vhomogeneous-folded` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -313,7 +313,7 @@ impl<O: IsA<Leaflet>> LeafletExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"vhomogeneous-unfolded\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `vhomogeneous-unfolded` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -327,7 +327,7 @@ impl<O: IsA<Leaflet>> LeafletExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<GString as StaticType>::static_type());
|
||||
gtk_sys::gtk_container_child_get_property(self.to_glib_none().0 as *mut gtk_sys::GtkContainer, item.to_glib_none().0 as *mut _, b"icon-name\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get()
|
||||
value.get().expect("Return Value for property `icon-name` getter")
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -341,7 +341,7 @@ impl<O: IsA<Leaflet>> LeafletExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<GString as StaticType>::static_type());
|
||||
gtk_sys::gtk_container_child_get_property(self.to_glib_none().0 as *mut gtk_sys::GtkContainer, item.to_glib_none().0 as *mut _, b"name\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get()
|
||||
value.get().expect("Return Value for property `name` getter")
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -355,7 +355,7 @@ impl<O: IsA<Leaflet>> LeafletExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gtk_sys::gtk_container_child_get_property(self.to_glib_none().0 as *mut gtk_sys::GtkContainer, item.to_glib_none().0 as *mut _, b"needs-attention\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `needs-attention` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -369,7 +369,7 @@ impl<O: IsA<Leaflet>> LeafletExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<i32 as StaticType>::static_type());
|
||||
gtk_sys::gtk_container_child_get_property(self.to_glib_none().0 as *mut gtk_sys::GtkContainer, item.to_glib_none().0 as *mut _, b"position\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `position` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -383,7 +383,7 @@ impl<O: IsA<Leaflet>> LeafletExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<GString as StaticType>::static_type());
|
||||
gtk_sys::gtk_container_child_get_property(self.to_glib_none().0 as *mut gtk_sys::GtkContainer, item.to_glib_none().0 as *mut _, b"title\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get()
|
||||
value.get().expect("Return Value for property `title` getter")
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -125,7 +125,7 @@ impl<O: IsA<SearchBar>> SearchBarExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"search-mode-enabled\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `search-mode-enabled` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -139,7 +139,7 @@ impl<O: IsA<SearchBar>> SearchBarExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"show-close-button\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `show-close-button` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -174,7 +174,7 @@ impl<O: IsA<Squeezer>> SqueezerExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"homogeneous\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `homogenous` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -188,7 +188,7 @@ impl<O: IsA<Squeezer>> SqueezerExt for O {
|
|||
unsafe {
|
||||
let mut value = Value::from_type(<bool as StaticType>::static_type());
|
||||
gobject_sys::g_object_get_property(self.to_glib_none().0 as *mut gobject_sys::GObject, b"interpolate-size\0".as_ptr() as *const _, value.to_glib_none_mut().0);
|
||||
value.get().unwrap()
|
||||
value.get().expect("Return Value for property `interpolate-size` getter").unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -8,8 +8,8 @@
|
|||
extern crate glib_sys;
|
||||
extern crate gobject_sys;
|
||||
extern crate gtk_sys;
|
||||
extern crate pango;
|
||||
extern crate libhandy_sys as handy_sys;
|
||||
extern crate pango;
|
||||
#[macro_use]
|
||||
extern crate glib;
|
||||
extern crate bitflags;
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
use glib;
|
||||
use ValueObject;
|
||||
use glib::translate::*;
|
||||
use glib::object::IsA;
|
||||
|
||||
impl ValueObject {
|
||||
#[cfg(any(feature = "v0_0_8", feature = "dox"))]
|
||||
|
|
Loading…
Reference in a new issue