2021-11-23 18:00:29 +00:00
|
|
|
import QtQml
|
|
|
|
import TestTypes
|
2022-08-23 08:42:35 +00:00
|
|
|
import TestTypes as TT2
|
2021-12-10 13:27:06 +00:00
|
|
|
import Ambiguous 1.2
|
2021-11-23 18:00:29 +00:00
|
|
|
|
|
|
|
QtObject {
|
2022-06-03 13:12:10 +00:00
|
|
|
id: self
|
2021-11-23 18:00:29 +00:00
|
|
|
property string attachedForNonObject: objectName.Component.objectName
|
|
|
|
property string attachedForNasty: Nasty.objectName
|
|
|
|
|
|
|
|
property Nasty nasty: Nasty {
|
|
|
|
objectName: Component.objectName
|
|
|
|
}
|
|
|
|
|
|
|
|
onFooBar: console.log("nope")
|
|
|
|
|
|
|
|
function doesReturnValue() { return 5; }
|
2021-12-10 13:27:06 +00:00
|
|
|
|
|
|
|
property Thing thing: Thing {
|
|
|
|
property int b: a + 1
|
|
|
|
}
|
|
|
|
|
2022-04-01 12:21:02 +00:00
|
|
|
property Thing2 thing2: Thing2 {
|
|
|
|
property int b: a + 2
|
|
|
|
}
|
|
|
|
|
2021-12-10 13:27:06 +00:00
|
|
|
property NotHere here: NotHere {
|
|
|
|
property int c: b + 1
|
|
|
|
}
|
2022-01-12 12:07:47 +00:00
|
|
|
|
|
|
|
Component.onCompleted: doesNotExist()
|
2022-06-03 13:12:10 +00:00
|
|
|
|
|
|
|
property string aString: self + "a"
|
2022-06-15 12:16:11 +00:00
|
|
|
|
|
|
|
property BirthdayParty party: BirthdayParty {
|
|
|
|
onPartyStarted: (foozle) => { objectName = foozle }
|
|
|
|
}
|
2022-06-24 12:40:02 +00:00
|
|
|
|
|
|
|
signal foo()
|
|
|
|
signal bar()
|
|
|
|
|
|
|
|
// Cannot assign potential undefined
|
|
|
|
onFoo: objectName = self.bar()
|
2022-08-23 08:42:35 +00:00
|
|
|
|
|
|
|
property int enumFromGadget1: GadgetWithEnum.CONNECTED + 1
|
|
|
|
property int enumFromGadget2: TT2.GadgetWithEnum.CONNECTED + 1
|
2021-11-23 18:00:29 +00:00
|
|
|
}
|