mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Copy changes from dev-branch into main
History of main branch was difficult to merge. Take a copy of dev-branch, and merge both ways between dev and main after the release.
This commit is contained in:
@@ -42,6 +42,14 @@ RiaPreferencesGeoMech::RiaPreferencesGeoMech()
|
||||
m_geomechWIACommand.uiCapability()->setUiEditorTypeName( caf::PdmUiFilePathEditor::uiEditorTypeName() );
|
||||
m_geomechWIACommand.uiCapability()->setUiLabelPosition( caf::PdmUiItemInfo::TOP );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_geomechFRMDefaultXML, "geomechFRMDefaultXML", "Default Parameter XML File" );
|
||||
m_geomechFRMDefaultXML.uiCapability()->setUiEditorTypeName( caf::PdmUiFilePathEditor::uiEditorTypeName() );
|
||||
m_geomechFRMDefaultXML.uiCapability()->setUiLabelPosition( caf::PdmUiItemInfo::TOP );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_geomechFRMCommand, "geomechFRMCommand", "Command to run" );
|
||||
m_geomechFRMCommand.uiCapability()->setUiEditorTypeName( caf::PdmUiFilePathEditor::uiEditorTypeName() );
|
||||
m_geomechFRMCommand.uiCapability()->setUiLabelPosition( caf::PdmUiItemInfo::TOP );
|
||||
|
||||
CAF_PDM_InitField( &m_keepTemporaryFiles, "keepTemporaryFile", false, "Keep temporary parameter files (for debugging)" );
|
||||
caf::PdmUiNativeCheckBoxEditor::configureFieldForEditor( &m_keepTemporaryFiles );
|
||||
|
||||
@@ -65,17 +73,14 @@ void RiaPreferencesGeoMech::appendItems( caf::PdmUiOrdering& uiOrdering ) const
|
||||
caf::PdmUiGroup* wellIAGroup = uiOrdering.addNewGroup( "Well Integrity Analysis" );
|
||||
wellIAGroup->add( &m_geomechWIACommand );
|
||||
wellIAGroup->add( &m_geomechWIADefaultXML );
|
||||
wellIAGroup->add( &m_waitForInputFileEdit );
|
||||
|
||||
caf::PdmUiGroup* faultRMGroup = uiOrdering.addNewGroup( "Fault Reactivation Modeling" );
|
||||
faultRMGroup->add( &m_geomechFRMCommand );
|
||||
faultRMGroup->add( &m_geomechFRMDefaultXML );
|
||||
|
||||
caf::PdmUiGroup* commonGroup = uiOrdering.addNewGroup( "Common Settings" );
|
||||
commonGroup->add( &m_keepTemporaryFiles );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RiaPreferencesGeoMech::defineUiOrdering( QString uiConfigName, caf::PdmUiOrdering& uiOrdering )
|
||||
{
|
||||
commonGroup->add( &m_waitForInputFileEdit );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -94,6 +99,22 @@ QString RiaPreferencesGeoMech::geomechWIADefaultXML() const
|
||||
return m_geomechWIADefaultXML;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
QString RiaPreferencesGeoMech::geomechFRMCommand() const
|
||||
{
|
||||
return m_geomechFRMCommand;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
QString RiaPreferencesGeoMech::geomechFRMDefaultXML() const
|
||||
{
|
||||
return m_geomechFRMDefaultXML;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -105,7 +126,7 @@ bool RiaPreferencesGeoMech::keepTemporaryFiles() const
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
bool RiaPreferencesGeoMech::waitBeforeRunWIA() const
|
||||
bool RiaPreferencesGeoMech::waitBeforeRun() const
|
||||
{
|
||||
return m_waitForInputFileEdit;
|
||||
}
|
||||
@@ -122,6 +143,17 @@ bool RiaPreferencesGeoMech::validateWIASettings() const
|
||||
return filesExists( files );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
bool RiaPreferencesGeoMech::validateFRMSettings() const
|
||||
{
|
||||
QStringList files;
|
||||
files << geomechFRMCommand();
|
||||
|
||||
return filesExists( files );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user