Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Check objects can be passed as signal parameters
Task-number: QTBUG-12457 Change-Id: I2d78c8885e488e51364fe4f2a30bde36fa78636a Reviewed-on: http://codereview.qt.nokia.com/2057 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
- Loading branch information
Aaron Kennedy
authored and
Qt by Nokia
committed
Jul 25, 2011
1 parent
9cb3889
commit 55aeb36
Showing
2 changed files
with
32 additions
and
0 deletions.
There are no files selected for viewing
18 changes: 18 additions & 0 deletions
18
tests/auto/declarative/qdeclarativeecmascript/data/objectsPassThroughSignals.qml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import QtQuick 1.0 | ||
|
||
QtObject { | ||
id: root | ||
|
||
property bool test: false | ||
|
||
signal mysignal(variant object); | ||
function myslot(object) | ||
{ | ||
test = (object == root); | ||
} | ||
|
||
Component.onCompleted: { | ||
mysignal.connect(this, myslot); | ||
mysignal(root); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters