aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qml/qmltc/QmltcTests/mySignals.qml
blob: 0348a0af54d4d695381f811113c9782d04f6026c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
// Copyright (C) 2022 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only

import QmltcTests
import QtQuick


TypeWithSignal {
    property int primitive
    property font gadget
    property QtObject object

    // value types by value
    onSignalWithPrimitive: (x) => { primitive = x; }
    onSignalWithGadget: (x) => { gadget = x; }

    // value types by const reference
    onSignalWithConstReferenceToGadget: (x) => { gadget = x; }

    // object by pointers
    onSignalWithPointer: (x) => { object = x; }
    onSignalWithPointerToConst: (x) => { object = x; }
    onSignalWithPointerToConst2: (x) => { object = x; }
    onSignalWithConstPointer: (x) => { object = x; }
    onSignalWithConstPointerToConst: (x) => { object = x; }
    onSignalWithConstPointerToConst2: (x) => { object = x; }
}