mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-13 17:02:13 -05:00
Refactor LayoutOptions to improve readability
* Make it possible to use designated initializer list - remove default constructor - move static member to outer scope * Add helper function to add field on same row
This commit is contained in:
1 parent
860f086af6
commit
678a368361
30 files changed
+198
-204
No files matched your search
@@ -259,9 +259,9 @@ void RimWellPathFracture::defineUiOrdering( QString uiConfigName, caf::PdmUiOrde
|
||||
|
||||
if ( m_fractureTemplate() )
|
||||
{
|
||||
uiOrdering.add( nameField(), caf::PdmUiOrdering::LayoutOptions( true, 3, 1 ) );
|
||||
uiOrdering.add( &m_fractureTemplate, { true, 2, 1 } );
|
||||
uiOrdering.add( &m_editFractureTemplate, { false, 1, 0 } );
|
||||
uiOrdering.add( nameField(), { .newRow = true, .totalColumnSpan = 3, .leftLabelColumnSpan = 1 } );
|
||||
uiOrdering.add( &m_fractureTemplate, { .totalColumnSpan = 2, .leftLabelColumnSpan = 1 } );
|
||||
uiOrdering.add( &m_editFractureTemplate, { .newRow = false, .totalColumnSpan = 1, .leftLabelColumnSpan = 0 } );
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -270,7 +270,7 @@ void RimWellPathFracture::defineUiOrdering( QString uiConfigName, caf::PdmUiOrde
|
||||
if ( RimProject::current()->allFractureTemplates().empty() )
|
||||
{
|
||||
uiOrdering.add( &m_createEllipseFractureTemplate );
|
||||
uiOrdering.add( &m_createStimPlanFractureTemplate, false );
|
||||
uiOrdering.appendToRow( &m_createStimPlanFractureTemplate );
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user