Re: [Vala] Button not visible
- From: Ulink <ulink gmx at>
- To: vala-list gnome org
- Subject: Re: [Vala] Button not visible
- Date: Wed, 5 Apr 2017 13:18:26 +0200
To work with signals i like to use *.clicked.connect. So i tried
box_pack_start (Gtk.Button revision = new Gtk.Button.with_label ("Add
new Revision"));
It looks like this isn't possible. What can i do?
Move revision outside from the box_pack_start() to access it from
outside, e.g. (not tested):
var revision = new Gtk.Button.with_label ("Add new Revision");
revision.clicked.connect(() => {
revision.label="You cowardly clicked me!";
});
box.pack_start(revision);
P.S.: You know "using Gtk;" on top of your source file? This avoids most
of (not all) the "Gtk." stuff.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]