Remove widget pointer from ChaperoneTabController
The pointer is not needed and is an anti pattern.
This commit is contained in:
@@ -485,7 +485,7 @@ void OverlayController::SetWidget( QQuickItem* quickItem,
|
|||||||
m_pPumpEventsTimer->start();
|
m_pPumpEventsTimer->start();
|
||||||
|
|
||||||
m_steamVRTabController.initStage2( this );
|
m_steamVRTabController.initStage2( this );
|
||||||
m_chaperoneTabController.initStage2( this, m_pWindow.get() );
|
m_chaperoneTabController.initStage2( this );
|
||||||
m_fixFloorTabController.initStage2( this, m_pWindow.get() );
|
m_fixFloorTabController.initStage2( this, m_pWindow.get() );
|
||||||
m_audioTabController.initStage2( this, m_pWindow.get() );
|
m_audioTabController.initStage2( this, m_pWindow.get() );
|
||||||
m_statisticsTabController.initStage2( this, m_pWindow.get() );
|
m_statisticsTabController.initStage2( this, m_pWindow.get() );
|
||||||
|
|||||||
@@ -47,11 +47,9 @@ void ChaperoneTabController::initStage1()
|
|||||||
eventLoopTick( nullptr, 0.0f, 0.0f, 0.0f );
|
eventLoopTick( nullptr, 0.0f, 0.0f, 0.0f );
|
||||||
}
|
}
|
||||||
|
|
||||||
void ChaperoneTabController::initStage2( OverlayController* var_parent,
|
void ChaperoneTabController::initStage2( OverlayController* var_parent )
|
||||||
QQuickWindow* var_widget )
|
|
||||||
{
|
{
|
||||||
this->parent = var_parent;
|
this->parent = var_parent;
|
||||||
this->widget = var_widget;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ChaperoneTabController::~ChaperoneTabController()
|
ChaperoneTabController::~ChaperoneTabController()
|
||||||
|
|||||||
@@ -135,7 +135,6 @@ class ChaperoneTabController : public QObject
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
OverlayController* parent;
|
OverlayController* parent;
|
||||||
QQuickWindow* widget;
|
|
||||||
|
|
||||||
float m_visibility = 0.6f;
|
float m_visibility = 0.6f;
|
||||||
float m_fadeDistance = 0.7f;
|
float m_fadeDistance = 0.7f;
|
||||||
@@ -193,7 +192,7 @@ public:
|
|||||||
~ChaperoneTabController();
|
~ChaperoneTabController();
|
||||||
|
|
||||||
void initStage1();
|
void initStage1();
|
||||||
void initStage2( OverlayController* parent, QQuickWindow* widget );
|
void initStage2( OverlayController* parent );
|
||||||
|
|
||||||
void eventLoopTick( vr::TrackedDevicePose_t* devicePoses,
|
void eventLoopTick( vr::TrackedDevicePose_t* devicePoses,
|
||||||
float leftSpeed,
|
float leftSpeed,
|
||||||
|
|||||||
Reference in New Issue
Block a user