Re: [Vala] vala-list Digest, Vol 61, Issue 7
- From: JM <interflug1 gmx net>
- To: vala-list gnome org
- Subject: Re: [Vala] vala-list Digest, Vol 61, Issue 7
- Date: Mon, 17 Dec 2012 10:54:36 +0100
Interesting. But this feature seems undocumented, I cannot find it in
the tutorial.
Am Sonntag, den 16.12.2012, 20:20 +0100 schrieb Jonas Kulla:
2012/12/16 JM <interflug1 gmx net>
Overriding a signal or making it virtual does not really make sense,
does it?
A signal does not have a body, as a function would have and signature is
always the same, even in child classes.
Also your example seems weird, as you have bodys for signals.
Regards
No, signals in Vala can be virtual and can have bodies.
GObject offers so called "default handles" for signals,
which can be specified as an offset in the class struct to the handler
function pointer. Because the handler is in the class struct,
it can be "overriden" by subclasses, hence the analogy "virtual signal".
Vala translates the signal body to a virtual function and sets it as the
default handler for the signal.
- Jonas
_______________________________________________
vala-list mailing list
vala-list gnome org
https://mail.gnome.org/mailman/listinfo/vala-list
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]