Details
-
Bug
-
Resolution: Cannot Reproduce
-
P3: Somewhat important
-
5.4.2
Description
Assume there has 3 singleton objects within a same package. They are A, B and C. Object B depends on Object A. Since Qt can not resolve singleton object within same package automatically. It need to add `import "."` statement in B.qml to make it works.
B.qml
import QtQuick 2.0 pragma Singleton import "." Item { /// Use A }
However, if C also depends on A. Then the QML application will just hang on startup.
I have attached an example code to prove it. The program should launch a window, but in fact it won't. It will just hang.
If you remove the `import "."` statement from either of B.qml / C.qml. Then it will work again. The bug happen if there has more than one `import "."` statement from singleton component within the package.
p.s Any workarounds for this problem?
Attachments
Issue Links
- relates to
-
QTBUG-64017 Regression [5.9.1 -> 5.9.2] QQmlApplicationEngine.load() fails silently
- Closed
-
QTBUG-63770 QtQuick Application window not showing up, process gets stuck
- Closed