AppFwk : Fixed typo of firstAncestorOrThisOfType

This commit is contained in:
Magne Sjaastad
2016-09-21 13:59:41 +02:00
parent 1bcfc41542
commit 531aaaa445
60 changed files with 124 additions and 122 deletions

View File

@@ -49,7 +49,7 @@ void RicAppendCrossSectionFeature::onActionTriggered(bool isChecked)
CVF_ASSERT(collection.size() == 1);
RimCrossSectionCollection* crossSectionCollection = NULL;
collection[0]->firstAnchestorOrThisOfType(crossSectionCollection);
collection[0]->firstAncestorOrThisOfType(crossSectionCollection);
CVF_ASSERT(crossSectionCollection);

View File

@@ -92,7 +92,7 @@ bool RicNewPolylineCrossSectionFeature::handleEvent(cvf::Object* eventObject)
if (crossSection->inputFromViewerEnabled())
{
RimCase* rimCase = NULL;
crossSection->firstAnchestorOrThisOfType(rimCase);
crossSection->firstAncestorOrThisOfType(rimCase);
CVF_ASSERT(rimCase);
crossSection->appendPointToPolyLine(rimCase->displayModelOffset() + polylineUiEvent->localIntersectionPoint);

View File

@@ -53,7 +53,7 @@ void RicNewSimWellCrossSectionFeature::onActionTriggered(bool isChecked)
RimEclipseWell* eclWell = collection[0];
RimEclipseView* eclView = NULL;
eclWell->firstAnchestorOrThisOfType(eclView);
eclWell->firstAncestorOrThisOfType(eclView);
CVF_ASSERT(eclView);
RicNewSimWellCrossSectionCmd* cmd = new RicNewSimWellCrossSectionCmd(eclView->crossSectionCollection, eclWell);

View File

@@ -99,7 +99,7 @@ RimIdenticalGridCaseGroup* RicPasteFeatureImpl::findGridCaseGroup(PdmObjectHandl
dynamic_cast<RimEclipseCase*>(objectHandle))
{
RimIdenticalGridCaseGroup* gridCaseGroup = NULL;
objectHandle->firstAnchestorOrThisOfType(gridCaseGroup);
objectHandle->firstAncestorOrThisOfType(gridCaseGroup);
return gridCaseGroup;
}

View File

@@ -45,7 +45,7 @@ bool RicAddEclipseInputPropertyFeature::isCommandEnabled()
{
RimEclipseInputCaseOpm* inputCaseOpm = NULL;
inputProp->firstAnchestorOrThisOfType(inputCaseOpm);
inputProp->firstAncestorOrThisOfType(inputCaseOpm);
if (inputCaseOpm)
{
return false;

View File

@@ -42,7 +42,7 @@ bool RicAddOpmInputPropertyFeature::isCommandEnabled()
{
RimEclipseInputCaseOpm* inputCaseOpm = NULL;
inputProp->firstAnchestorOrThisOfType(inputCaseOpm);
inputProp->firstAncestorOrThisOfType(inputCaseOpm);
if (inputCaseOpm)
{
return true;
@@ -103,7 +103,7 @@ void RicAddOpmInputPropertyFeature::addEclipseInputProperty(const QStringList& f
RimEclipseInputCaseOpm* inputCaseOpm = NULL;
inputPropertyCollection->firstAnchestorOrThisOfType(inputCaseOpm);
inputPropertyCollection->firstAncestorOrThisOfType(inputCaseOpm);
if (inputCaseOpm)
{
inputCaseOpm->appendPropertiesFromStandaloneFiles(fileNames);

View File

@@ -220,7 +220,7 @@ bool RicCloseCaseFeature::userConfirmedGridCaseGroupChange(const std::vector<Rim
for (size_t i = 0; i < casesToBeDeleted.size(); i++)
{
RimIdenticalGridCaseGroup* gridCaseGroup = NULL;
casesToBeDeleted[i]->firstAnchestorOrThisOfType(gridCaseGroup);
casesToBeDeleted[i]->firstAncestorOrThisOfType(gridCaseGroup);
if (gridCaseGroup && hasAnyStatisticsResults(gridCaseGroup))
{

View File

@@ -44,7 +44,7 @@ bool RicComputeStatisticsFeature::isCommandEnabled()
if (statisticsCase)
{
RimIdenticalGridCaseGroup* gridCaseGroup = NULL;
statisticsCase->firstAnchestorOrThisOfType(gridCaseGroup);
statisticsCase->firstAncestorOrThisOfType(gridCaseGroup);
RimCaseCollection* caseCollection = gridCaseGroup ? gridCaseGroup->caseCollection() : NULL;
return caseCollection ? caseCollection->reservoirs.size() > 0 : false;

View File

@@ -81,10 +81,10 @@ void RicDeleteItemExec::redo()
parentObj->uiCapability()->updateConnectedEditors();
RimView* view = NULL;
parentObj->firstAnchestorOrThisOfType(view);
parentObj->firstAncestorOrThisOfType(view);
RimCellRangeFilterCollection* rangeFilterColl;
parentObj->firstAnchestorOrThisOfType(rangeFilterColl);
parentObj->firstAncestorOrThisOfType(rangeFilterColl);
if (rangeFilterColl)
{
@@ -92,10 +92,10 @@ void RicDeleteItemExec::redo()
}
RimEclipsePropertyFilterCollection* eclipsePropColl;
parentObj->firstAnchestorOrThisOfType(eclipsePropColl);
parentObj->firstAncestorOrThisOfType(eclipsePropColl);
RimGeoMechPropertyFilterCollection* geoMechPropColl;
parentObj->firstAnchestorOrThisOfType(geoMechPropColl);
parentObj->firstAncestorOrThisOfType(geoMechPropColl);
if (view && (eclipsePropColl || geoMechPropColl))
{
@@ -104,14 +104,14 @@ void RicDeleteItemExec::redo()
}
RimCrossSectionCollection* crossSectionColl;
parentObj->firstAnchestorOrThisOfType(crossSectionColl);
parentObj->firstAncestorOrThisOfType(crossSectionColl);
if (view && crossSectionColl)
{
view->scheduleCreateDisplayModelAndRedraw();
}
RimWellPathCollection* wellPathColl;
parentObj->firstAnchestorOrThisOfType(wellPathColl);
parentObj->firstAncestorOrThisOfType(wellPathColl);
if (wellPathColl)
{
@@ -121,7 +121,7 @@ void RicDeleteItemExec::redo()
// Update due to deletion of curves (not tracks, handled separatly)
RimWellLogPlot* wellLogPlot;
parentObj->firstAnchestorOrThisOfType(wellLogPlot);
parentObj->firstAncestorOrThisOfType(wellLogPlot);
if (wellLogPlot)
{
wellLogPlot->calculateAvailableDepthRange();
@@ -129,7 +129,7 @@ void RicDeleteItemExec::redo()
}
RimWellLogTrack* wellLogPlotTrack;
parentObj->firstAnchestorOrThisOfType(wellLogPlotTrack);
parentObj->firstAncestorOrThisOfType(wellLogPlotTrack);
if (wellLogPlotTrack)
{
wellLogPlotTrack->updateXZoom();
@@ -144,7 +144,7 @@ void RicDeleteItemExec::redo()
if (wellLogPlotCollection->wellLogPlots.empty())
{
RimProject* project = NULL;
parentObj->firstAnchestorOrThisOfType(project);
parentObj->firstAncestorOrThisOfType(project);
if (project)
{
project->updateConnectedEditors();
@@ -153,13 +153,13 @@ void RicDeleteItemExec::redo()
}
RimViewLinkerCollection* viewLinkerCollection = NULL;
parentObj->firstAnchestorOrThisOfType(viewLinkerCollection);
parentObj->firstAncestorOrThisOfType(viewLinkerCollection);
if (viewLinkerCollection)
{
viewLinkerCollection->uiCapability()->updateConnectedEditors();
RimProject* project = NULL;
parentObj->firstAnchestorOrThisOfType(project);
parentObj->firstAncestorOrThisOfType(project);
if (project)
{
// Update visibility of top level Linked Views item in the project tree

View File

@@ -90,7 +90,7 @@ void RicEclipsePropertyFilterFeatureImpl::insertPropertyFilter(RimEclipsePropert
bool RicEclipsePropertyFilterFeatureImpl::isPropertyFilterCommandAvailable(caf::PdmObjectHandle* object)
{
RimView* rimView = NULL;
object->firstAnchestorOrThisOfType(rimView);
object->firstAncestorOrThisOfType(rimView);
if (rimView)
{
RimViewController* vc = rimView->viewController();

View File

@@ -38,7 +38,7 @@ bool RicRangeFilterFeatureImpl::isRangeFilterCommandAvailable()
if (!rangeFilterCollection) return false;
RimView* view;
rangeFilterCollection->firstAnchestorOrThisOfType(view);
rangeFilterCollection->firstAncestorOrThisOfType(view);
if (view)
{
RimViewController* vc = view->viewController();
@@ -80,7 +80,7 @@ RimCellRangeFilterCollection* RicRangeFilterFeatureImpl::findRangeFilterCollecti
}
else if (selectedRangeFilter.size() > 0)
{
selectedRangeFilter[0]->firstAnchestorOrThisOfType(rangeFilterCollection);
selectedRangeFilter[0]->firstAncestorOrThisOfType(rangeFilterCollection);
}
assert(rangeFilterCollection);

View File

@@ -82,7 +82,7 @@ QList<caf::PdmOptionItemInfo> RicLinkVisibleViewsFeatureUi::calculateValueOption
for (size_t i = 0; i < m_allViews.size(); i++)
{
RimCase* rimCase = NULL;
m_allViews[i]->firstAnchestorOrThisOfType(rimCase);
m_allViews[i]->firstAncestorOrThisOfType(rimCase);
QIcon icon;
if (rimCase)

View File

@@ -50,7 +50,7 @@ void RicShowAllLinkedViewsFeature::onActionTriggered(bool isChecked)
for (size_t i = 0; i < managedViews.size(); i++)
{
RimViewLinker* rimLinked = NULL;
managedViews[i]->firstAnchestorOrThisOfType(rimLinked);
managedViews[i]->firstAncestorOrThisOfType(rimLinked);
CVF_ASSERT(rimLinked);
linkedViews.push_back(rimLinked);

View File

@@ -78,10 +78,10 @@ void RicAddWellLogToPlotFeature::onActionTriggered(bool isChecked)
RimWellLogFileChannel* wellLog = selection[wlIdx];
RimWellPath* wellPath = NULL;
wellLog->firstAnchestorOrThisOfType(wellPath);
wellLog->firstAncestorOrThisOfType(wellPath);
RimWellLogFile* wellLogFile = NULL;
wellLog->firstAnchestorOrThisOfType(wellLogFile);
wellLog->firstAncestorOrThisOfType(wellLogFile);
if (wellLogFile)
{
RimWellLogFileCurve* curve = new RimWellLogFileCurve;

View File

@@ -40,7 +40,7 @@ bool RicDeleteWellLogPlotTrackFeature::isCommandEnabled()
if (selection.size() > 0)
{
RimWellLogPlot* wellLogPlot = NULL;
selection[0]->firstAnchestorOrThisOfType(wellLogPlot);
selection[0]->firstAncestorOrThisOfType(wellLogPlot);
if (wellLogPlot->trackCount() > 1)
{
return true;
@@ -63,7 +63,7 @@ void RicDeleteWellLogPlotTrackFeature::onActionTriggered(bool isChecked)
RimWellLogTrack* track = selection[i];
RimWellLogPlot* wellLogPlot = NULL;
track->firstAnchestorOrThisOfType(wellLogPlot);
track->firstAncestorOrThisOfType(wellLogPlot);
if (wellLogPlot && wellLogPlot->trackCount() > 1)
{
wellLogPlot->removeTrack(track);

View File

@@ -71,7 +71,7 @@ void RicNewWellLogCurveExtractionFeature::onActionTriggered(bool isChecked)
plotCurve->loadDataAndUpdate();
RimWellLogPlot* plot = NULL;
wellLogPlotTrack->firstAnchestorOrThisOfType(plot);
wellLogPlotTrack->firstAncestorOrThisOfType(plot);
if (plot && plotCurve->curveData())
{
plot->setDepthUnit(plotCurve->curveData()->depthUnit());

View File

@@ -168,7 +168,7 @@ void RicNewWellLogFileCurveFeature::addWellLogChannelsToPlotTrack(RimWellLogTrac
RimWellLogFileCurve* plotCurve = addCurve(plotTrack);
RimWellPath* wellPath;
wellLogFileChannels[cIdx]->firstAnchestorOrThisOfType(wellPath);
wellLogFileChannels[cIdx]->firstAncestorOrThisOfType(wellPath);
if (wellPath)
{
plotCurve->setWellPath(wellPath);

View File

@@ -43,14 +43,14 @@ void RicWellLogPlotTrackFeatureImpl::moveCurvesToWellLogPlotTrack(RimWellLogTrac
RimWellLogCurve* curve = curves[cIdx];
RimWellLogTrack* wellLogPlotTrack;
curve->firstAnchestorOrThisOfType(wellLogPlotTrack);
curve->firstAncestorOrThisOfType(wellLogPlotTrack);
if (wellLogPlotTrack)
{
wellLogPlotTrack->removeCurve(curve);
wellLogPlotTrack->updateConnectedEditors();
srcTracks.insert(wellLogPlotTrack);
RimWellLogPlot* plot;
wellLogPlotTrack->firstAnchestorOrThisOfType(plot);
wellLogPlotTrack->firstAncestorOrThisOfType(plot);
if (plot) srcPlots.insert(plot);
}
}
@@ -94,7 +94,7 @@ void RicWellLogPlotTrackFeatureImpl::moveTracksToWellLogPlot(RimWellLogPlot* dst
RimWellLogTrack* track = tracksToMove[tIdx];
RimWellLogPlot* srcPlot;
track->firstAnchestorOrThisOfType(srcPlot);
track->firstAncestorOrThisOfType(srcPlot);
if (srcPlot)
{
srcPlot->removeTrack(track);

View File

@@ -61,7 +61,7 @@ void RicWellPathDeleteFeature::onActionTriggered(bool isChecked)
RimWellPath* wellPath = objects[0];
RimWellPathCollection* wellPathCollection = NULL;
wellPath->firstAnchestorOrThisOfType(wellPathCollection);
wellPath->firstAncestorOrThisOfType(wellPathCollection);
wellPathCollection->removeWellPath(wellPath);;
delete wellPath;

View File

@@ -60,7 +60,7 @@ bool RicWellPathViewerEventHandler::handleEvent(cvf::Object* eventObject)
if (!activeView) return false;
RimCase* rimCase = NULL;
activeView->firstAnchestorOrThisOfType(rimCase);
activeView->firstAncestorOrThisOfType(rimCase);
if (rimCase)
{
displayModelOffset = rimCase->displayModelOffset();