[Interest] Creating Singals from QtScript
hundertmarck at boehme-weihs.de
hundertmarck at boehme-weihs.de
Thu Nov 3 12:55:42 CET 2011
Hi,
I'm trying to create a signal in QtScript and connect it to an QtScript method. Is it already possible?
Example:
cls1 = function()
{
this.sig1 = signal(); // This method does not exists, is there an equivalent expression?
}
cls2 = function()
{
this.slot1 = function()
{
alert("slot1"); // Is definied by Application
}
}
var i1 = new cls1();
var i2 = new cls2();
// connect
i1.sig1.connect(i2.slot1);
// Emit
i1.sig1();
Thanks,
Jörg Hundertmarck
______________________________________________________________
Böhme & Weihs Systemtechnik GmbH & Co. KG
Engelsfeld 9
45549 Sprockhövel, Germany
www.boehme-weihs.de
Tel. +49 2339 9182-0
Fax +49 2339 9182-99
www.boehme-weihs.com
HRB: 14870 l Amtsgericht Essen
Geschäftsführer: Prof. Dr. Norbert Böhme l Dipl.-Ing. Norbert Seeliger l Rüdiger Weihs l Dipl.-Ing. Joachim Wendel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20111103/ef29000e/attachment.html>
More information about the Interest
mailing list