diff options
author | Simon Hausmann <simon.hausmann@qt.io> | 2019-07-09 09:12:01 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@qt.io> | 2019-07-10 09:24:27 +0000 |
commit | c27554068efe63d2093d6a28cc83cb95190003a2 (patch) | |
tree | 0dbe40277a7c5d3c988630d15ef40c5d2dd96da2 /src/qml/doc/snippets/qml/statemachine/guardcondition.qml | |
parent | 1c84e6debfc05e60f1f331ba5f1f265ec6590a8b (diff) |
Fix docs to explain the new type syntax for QML methods
[ChangeLog][QtQml] It is now possible to specify types for method
parameters and their return value in QML (basic and object types), using
TypeScript-like syntax with a colon separator. The syntax for QML
declared signals supports the same style.
This change also adapts the remaining snippets and docs to the "fresher"
qml signal parameter syntax.
Change-Id: I601781f01f696276951b04785584adab39fedfd9
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'src/qml/doc/snippets/qml/statemachine/guardcondition.qml')
-rw-r--r-- | src/qml/doc/snippets/qml/statemachine/guardcondition.qml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qml/doc/snippets/qml/statemachine/guardcondition.qml b/src/qml/doc/snippets/qml/statemachine/guardcondition.qml index 8388b96c21..f1ec89b6ba 100644 --- a/src/qml/doc/snippets/qml/statemachine/guardcondition.qml +++ b/src/qml/doc/snippets/qml/statemachine/guardcondition.qml @@ -70,7 +70,7 @@ Rectangle { } } // define the signal the SignalTransition is connected with - signal mysignal(string mystr) + signal mysignal(mystr: string) // on clicking the button emit the signal with a single string argument onClicked: button.mysignal("test") } |