[TD] Gui: remove some superfluous nullptr checks

This commit is contained in:
Uwe
2022-07-19 02:49:46 +02:00
parent 003757176c
commit 2e5e4dced8
38 changed files with 154 additions and 160 deletions

View File

@@ -160,7 +160,7 @@ void TaskProjGroup::saveGroupState()
for( const auto it : multiView->Views.getValues() ) {
auto view( dynamic_cast<DrawProjGroupItem *>(it) );
if (view != nullptr) {
if (view) {
m_saveViewNames.push_back(view->Type.getValueAsString());
}
}
@@ -441,7 +441,7 @@ const char * TaskProjGroup::viewChkIndexToCStr(int index)
// First Angle: FBRight B FBL
// Right F L Rear
// FTRight T FTL
assert (multiView != nullptr);
assert (multiView);
bool thirdAngle = multiView->usedProjectionType().isValue("Third Angle");
switch(index) {
@@ -484,7 +484,7 @@ void TaskProjGroup::setupViewCheckboxes(bool addConnections)
}
const char *viewStr = viewChkIndexToCStr(i);
if ( viewStr != nullptr && multiView->hasProjection(viewStr) ) {
if (viewStr && multiView->hasProjection(viewStr)) {
box->setCheckState(Qt::Checked);
} else {
box->setCheckState(Qt::Unchecked);