mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Update clang-tidy.yml
* Make sure clang-tidy action use .clang-tidy config file Use add-paths to instruct create-pull-request to a sub folder to avoid diff from Qt and vcpkg * Use empty() in macro to avoid clang-tidy warning * Add NOLINT to CAF_ASSERT * Add NOLINT to cvfAssert
This commit is contained in:
@@ -168,9 +168,7 @@ bool RicfCreateMultipleFractures::validateArguments() const
|
||||
{
|
||||
bool valid = m_caseId >= 0 && m_templateId >= 0;
|
||||
|
||||
if ( valid ) return true;
|
||||
|
||||
return false;
|
||||
return valid;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -35,7 +35,6 @@
|
||||
#include "RiaLogging.h"
|
||||
#include "RiaWellNameComparer.h"
|
||||
|
||||
#include "cafCmdFeatureManager.h"
|
||||
#include "cafPdmFieldScriptingCapability.h"
|
||||
|
||||
#include <QStringList>
|
||||
@@ -90,9 +89,6 @@ caf::PdmScriptResponse RicfExportLgrForCompletions::execute()
|
||||
exportFolder = RiaApplication::instance()->createAbsolutePathFromProjectRelativePath( "LGR" );
|
||||
}
|
||||
|
||||
caf::CmdFeatureManager* commandManager = caf::CmdFeatureManager::instance();
|
||||
auto feature = dynamic_cast<RicExportLgrFeature*>( commandManager->getCommandFeature( "RicExportLgrFeature" ) );
|
||||
|
||||
RimEclipseCase* eclipseCase = TOOLS::caseFromId( m_caseId() );
|
||||
if ( !eclipseCase )
|
||||
{
|
||||
@@ -104,16 +100,16 @@ caf::PdmScriptResponse RicfExportLgrForCompletions::execute()
|
||||
caf::VecIjk lgrCellCounts( m_refinementI, m_refinementJ, m_refinementK );
|
||||
QStringList wellsIntersectingOtherLgrs;
|
||||
|
||||
feature->exportLgrsForWellPaths( exportFolder,
|
||||
wellPaths,
|
||||
eclipseCase,
|
||||
m_timeStep,
|
||||
lgrCellCounts,
|
||||
m_splitType(),
|
||||
{ RigCompletionData::CompletionType::PERFORATION,
|
||||
RigCompletionData::CompletionType::FRACTURE,
|
||||
RigCompletionData::CompletionType::FISHBONES },
|
||||
&wellsIntersectingOtherLgrs );
|
||||
RicExportLgrFeature::exportLgrsForWellPaths( exportFolder,
|
||||
wellPaths,
|
||||
eclipseCase,
|
||||
m_timeStep,
|
||||
lgrCellCounts,
|
||||
m_splitType(),
|
||||
{ RigCompletionData::CompletionType::PERFORATION,
|
||||
RigCompletionData::CompletionType::FRACTURE,
|
||||
RigCompletionData::CompletionType::FISHBONES },
|
||||
&wellsIntersectingOtherLgrs );
|
||||
|
||||
caf::PdmScriptResponse response;
|
||||
if ( !wellsIntersectingOtherLgrs.empty() )
|
||||
|
||||
@@ -89,7 +89,7 @@ caf::PdmScriptResponse RicfExportSnapshots::execute()
|
||||
QByteArray curState = mainWnd->dockManager()->saveState( 0 );
|
||||
mainWnd->dockManager()->restoreState( RiuDockWidgetTools::defaultDockState( RiuDockWidgetTools::dockStateHideAll3DWindowName() ) );
|
||||
|
||||
RiaGuiApplication::instance()->processEvents();
|
||||
QApplication::processEvents();
|
||||
|
||||
QString absolutePathToSnapshotDir = RicfCommandFileExecutor::instance()->getExportPath( RicfCommandFileExecutor::ExportType::SNAPSHOTS );
|
||||
|
||||
@@ -131,7 +131,7 @@ caf::PdmScriptResponse RicfExportSnapshots::execute()
|
||||
RicSnapshotAllPlotsToFileFeature::exportSnapshotOfPlotsIntoFolder( absolutePathToSnapshotDir, activateWidget, m_prefix, m_viewId(), fileSuffix );
|
||||
}
|
||||
|
||||
RiaGuiApplication::instance()->processEvents();
|
||||
QApplication::processEvents();
|
||||
|
||||
mainWnd->dockManager()->restoreState( curState );
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ public:
|
||||
PNG,
|
||||
PDF
|
||||
};
|
||||
typedef caf::AppEnum<PlotOutputFormat> PreferredOutputFormatEnum;
|
||||
using PreferredOutputFormatEnum = caf::AppEnum<PlotOutputFormat>;
|
||||
|
||||
enum class SnapshotsType
|
||||
{
|
||||
@@ -48,7 +48,7 @@ public:
|
||||
PLOTS,
|
||||
ALL
|
||||
};
|
||||
typedef caf::AppEnum<SnapshotsType> SnapshotsTypeEnum;
|
||||
using SnapshotsTypeEnum = caf::AppEnum<SnapshotsType>;
|
||||
|
||||
public:
|
||||
RicfExportSnapshots();
|
||||
|
||||
@@ -54,7 +54,7 @@ public:
|
||||
LAS,
|
||||
ASCII
|
||||
};
|
||||
typedef caf::AppEnum<ExportFormat> ExportFormatEnum;
|
||||
using ExportFormatEnum = caf::AppEnum<ExportFormat>;
|
||||
|
||||
public:
|
||||
RicfExportWellLogPlotData();
|
||||
|
||||
@@ -35,7 +35,6 @@
|
||||
#include "RiaLogging.h"
|
||||
#include "RiaWellNameComparer.h"
|
||||
|
||||
#include "cafCmdFeatureManager.h"
|
||||
#include "cafPdmFieldScriptingCapability.h"
|
||||
|
||||
CAF_PDM_SOURCE_INIT( RicfExportWellPaths, "exportWellPaths" );
|
||||
@@ -83,15 +82,11 @@ caf::PdmScriptResponse RicfExportWellPaths::execute()
|
||||
exportFolder = RiaApplication::instance()->createAbsolutePathFromProjectRelativePath( "wellpaths" );
|
||||
}
|
||||
|
||||
caf::CmdFeatureManager* commandManager = caf::CmdFeatureManager::instance();
|
||||
auto feature =
|
||||
dynamic_cast<RicExportSelectedWellPathsFeature*>( commandManager->getCommandFeature( "RicExportSelectedWellPathsFeature" ) );
|
||||
|
||||
for ( const auto wellPath : wellPaths )
|
||||
{
|
||||
if ( wellPath )
|
||||
{
|
||||
feature->exportWellPath( wellPath, m_mdStepSize, exportFolder, false );
|
||||
RicExportSelectedWellPathsFeature::exportWellPath( wellPath, m_mdStepSize, exportFolder, false );
|
||||
}
|
||||
}
|
||||
return caf::PdmScriptResponse();
|
||||
|
||||
Reference in New Issue
Block a user