Re: [Vala] GBinding support?

2010-06-21 Thread Fredderic Unpenstein
On 21 June 2010 01:57, Frederik scumm_fr...@gmx.net wrote: GLib/GObject 2.26 will add property binding [1]. The straightforward way to support this in Vala would be:  Object.bind_property (foo, x, bar, y);  Object.bind_property (foo, x, bar, y, BindingFlags.BIDIRECTIONAL); Would

Re: [Vala] GBinding support?

2010-06-21 Thread Frederik
Am 21.06.2010 09:29, Fredderic Unpenstein wrote: On 21 June 2010 01:57, Frederik scumm_fr...@gmx.net wrote: GLib/GObject 2.26 will add property binding [1]. The straightforward way to support this in Vala would be: Object.bind_property (foo, x, bar, y); Object.bind_property (foo, x, bar, y,

Re: [Vala] GBinding support?

2010-06-21 Thread Frederik
Am 21.06.2010 05:51, Matias De la Puente wrote: This stuff is great! very helpful for my project :) My suggestions: public class foo : Object { public int x { set; get; } public int y { set; get; } } public class bar : Object { private Foo foo = new Foo ();

Re: [Vala] GBinding support?

2010-06-21 Thread Jürg Billeter
Hi, On Sun, 2010-06-20 at 17:57 +0200, Frederik wrote: GLib/GObject 2.26 will add property binding [1]. The straightforward way to support this in Vala would be: Object.bind_property (foo, x, bar, y); Object.bind_property (foo, x, bar, y, BindingFlags.BIDIRECTIONAL); However, this is

[Vala] GBinding support?

2010-06-20 Thread Frederik
Hi, GLib/GObject 2.26 will add property binding [1]. The straightforward way to support this in Vala would be: Object.bind_property (foo, x, bar, y); Object.bind_property (foo, x, bar, y, BindingFlags.BIDIRECTIONAL); However, this is not very type-safe. Would direct language support be

Re: [Vala] GBinding support?

2010-06-20 Thread Fabian Deutsch
Hello, Am Sonntag, den 20.06.2010, 17:57 +0200 schrieb Frederik: foo.x + bar.y; // default foo.x + bar.y; // bidirectional I'd suggest ~ or -, because a change of a 'implies' a value change of b: foo.x ~ bar.y; // default foo.x ~ bar.y; // bidirectional -

Re: [Vala] GBinding support?

2010-06-20 Thread Matias De la Puente
This stuff is great! very helpful for my project :) My suggestions: public class foo : Object { public int x { set; get; } public int y { set; get; } } public class bar : Object { private Foo foo = new Foo (); //One possibility public int x {