Qt widget promotion error after moving code and ui files.
-
wrote on 20 Jul 2019, 03:46 last edited by
Class DCGraphicsView is a subclass of QGraphicsView, I put a QGraphicsView Widget on the UI file framework.ui. And the I promote that QGraphicsView Widget to DCGraphicsView. After clean, qmake and rebuild, everything is OK as expected.
But after I moved those code and ui file into a subfolder named ui, and modify the pro as well, use the same procedure as previous (clean, qmake and rebuild). An error message displayed when doing rebuild.
To figure out what causes this error, I cancel the promotion of QGraphicsView Widget, then no error pops out. If I put it back, the same error comes again. Confused.
error message as follows:
No rule to make target 'dcgraphicsview.h', needed by 'ui_framework.h'.Stop.
-
wrote on 20 Jul 2019, 04:47 last edited by
I got a solution, use
UI_DIR
to the ui file path inpro
file.
1/2