Skip to content
Snippets Groups Projects
Commit cb65ee40 authored by l.dressen's avatar l.dressen
Browse files

set calibration tab as default as PeTrack launches

parent fa057093
No related branches found
No related tags found
1 merge request!409set calibration tab as default as PeTrack launches
......@@ -285,6 +285,9 @@ Control::Control(
mCorrectionWidget = new Correction(mMainWindow, mMainWindow->getPersonStorage(), this);
mUi->tabs->insertTab(3, mCorrectionWidget, "correction");
// set calibration as default tab when opening PeTrack
mUi->tabs->setCurrentIndex(0);
connect(
mUi->trackShowComplPath,
&QCheckBox::stateChanged,
......@@ -303,6 +306,11 @@ void Control::setScene(QGraphicsScene *sc)
mScene = sc;
}
int Control::getCurrentTab() const
{
return mUi->tabs->currentIndex();
}
void Control::toggleOnlineTracking()
{
mUi->trackOnlineCalc->toggle();
......
......@@ -81,6 +81,7 @@ public:
AlignmentGridBox *gridBox);
void setScene(QGraphicsScene *sc);
int getCurrentTab() const;
void toggleOnlineTracking();
bool isOnlineTrackingChecked() const;
......
......@@ -74,7 +74,7 @@
<enum>Qt::LeftToRight</enum>
</property>
<property name="currentIndex">
<number>1</number>
<number>0</number>
</property>
<property name="tabsClosable">
<bool>false</bool>
......@@ -129,7 +129,7 @@
<enum>Qt::ScrollBarAlwaysOff</enum>
</property>
<property name="sizeAdjustPolicy">
<enum>QAbstractScrollArea::SizeAdjustPolicy::AdjustToContents</enum>
<enum>QAbstractScrollArea::AdjustToContents</enum>
</property>
<property name="widgetResizable">
<bool>true</bool>
......@@ -988,7 +988,7 @@
<enum>QFrame::StyledPanel</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Shadow::Raised</enum>
<enum>QFrame::Raised</enum>
</property>
</widget>
</item>
......@@ -1575,7 +1575,7 @@
<enum>Qt::ScrollBarAlwaysOff</enum>
</property>
<property name="sizeAdjustPolicy">
<enum>QAbstractScrollArea::SizeAdjustPolicy::AdjustToContents</enum>
<enum>QAbstractScrollArea::AdjustToContents</enum>
</property>
<property name="widgetResizable">
<bool>true</bool>
......@@ -1589,7 +1589,7 @@
<x>0</x>
<y>0</y>
<width>516</width>
<height>1293</height>
<height>1266</height>
</rect>
</property>
<property name="sizePolicy">
......@@ -2722,7 +2722,7 @@
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Policy::Fixed</enum>
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
......@@ -3758,7 +3758,7 @@
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Policy::Fixed</enum>
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
......@@ -4078,7 +4078,7 @@
<enum>QFrame::StyledPanel</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Shadow::Raised</enum>
<enum>QFrame::Raised</enum>
</property>
</widget>
</item>
......
......@@ -407,3 +407,10 @@ TEST_CASE("Control: ROI fixed synchronized")
CHECK(control->getRecoRoiFix() == recoROI->isFixed());
}
}
TEST_CASE("Calibration tab is open per default")
{
Petrack pet{"Unknown"};
Control *control = pet.getControlWidget();
CHECK(control->getCurrentTab() == 0);
}
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