Skip to content
Snippets Groups Projects
Commit 7154bf0f authored by burneykb's avatar burneykb
Browse files

small fixes to QuadItem

parent 421ba3dc
No related branches found
No related tags found
No related merge requests found
......@@ -23,11 +23,12 @@ MainWindow::MainWindow(QWidget *parent) :
nextSpTimer(new QTimer(this)),
sp_x(0.0f),
sp_y(0.0f),
sp_z(0.0f),
topScene(new QGraphicsScene(this)),
quad(new QuadItem)
sp_z(0.0f)
{
ui->setupUi(this);
QGraphicsScene *topScene = new QGraphicsScene(this);
QuadItem * quad = new QuadItem(this);
ui->topView->setScene(topScene);
topScene->addItem(quad);
......@@ -50,7 +51,7 @@ MainWindow::MainWindow(QWidget *parent) :
this, SLOT (updateTracker(float, float, float, float, float, float)));
connect(trackerWorker, SIGNAL (finished(float, float, float, float, float, float)),
this, SLOT (updateQuad(float, float, float, float, float, float)));
this, SLOT (quad->updateQuad(float, float, float, float, float, float)));
/* Create another worker for the control graph */
QThread * cwThread = new QThread(this);
......
......@@ -81,9 +81,6 @@ private:
float sp_x;
float sp_y;
float sp_z;
QGraphicsScene * topScene;
QuadItem * quad;
};
#endif // MAINWINDOW_H
......@@ -2,8 +2,9 @@
#include <QPixmap>
#include <QLabel>
QuadItem::QuadItem()
QuadItem::QuadItem(QGraphicsItem* parent = nullptr)
{
this->setParentItem(parent);
setFlag(ItemIsMovable);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment