nitlanguage
/
nit.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b96d887
)
lib/linux: implement ToggleEvent
author
Alexis Laferrière
<alexis.laf@xymus.net>
Tue, 17 May 2016 14:53:51 +0000
(10:53 -0400)
committer
Alexis Laferrière
<alexis.laf@xymus.net>
Tue, 17 May 2016 14:53:51 +0000
(10:53 -0400)
Signed-off-by: Alexis Laferrière <alexis.laf@xymus.net>
lib/linux/ui.nit
patch
|
blob
|
history
diff --git
a/lib/linux/ui.nit
b/lib/linux/ui.nit
index
ca004a0
..
fa850d4
100644
(file)
--- a/
lib/linux/ui.nit
+++ b/
lib/linux/ui.nit
@@
-294,6
+294,9
@@
redef class CheckBox
redef type NATIVE: GtkCheckButton
redef var native = new GtkCheckButton
+ redef fun signal(sender, data) do notify_observers new ToggleEvent(self)
+ init do native.signal_connect("toggled", self, null)
+
redef fun text do return native.text
redef fun text=(value) do native.text = (value or else "").to_s