mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#5001 Show result info when picking RimWellMeasurement in 3d view.
This commit is contained in:
parent
37ab75bc2a
commit
e380168f13
@ -24,6 +24,8 @@
|
||||
#include "Rim2dIntersectionView.h"
|
||||
#include "Rim3dView.h"
|
||||
#include "RimPerforationInterval.h"
|
||||
#include "RimWellMeasurement.h"
|
||||
#include "RimWellMeasurementCollection.h"
|
||||
#include "RimWellPath.h"
|
||||
#include "RimWellPathAttribute.h"
|
||||
#include "RimWellPathAttributeCollection.h"
|
||||
@ -130,6 +132,35 @@ bool RicWellPathPickEventHandler::handle3dPickEvent( const Ric3dPickEvent& event
|
||||
RiuMainWindow::instance()->setResultInfo( attrText );
|
||||
RiuMainWindow::instance()->selectAsCurrentItem( collection );
|
||||
}
|
||||
else if ( dynamic_cast<RimWellMeasurement*>( sourceInfo->object() ) )
|
||||
{
|
||||
RimWellMeasurement* measurement = dynamic_cast<RimWellMeasurement*>( sourceInfo->object() );
|
||||
RimWellMeasurementCollection* collection = nullptr;
|
||||
measurement->firstAncestorOrThisOfTypeAsserted( collection );
|
||||
|
||||
QString measurementText = QString( "Well path name: %1\n" ).arg( measurement->wellName() );
|
||||
measurementText += QString( "Measured Depth: %1\n" ).arg( measurement->MD() );
|
||||
measurementText += QString( "Value: %1\n" ).arg( measurement->value() );
|
||||
measurementText += QString( "Date: %1\n" ).arg( measurement->date().toString() );
|
||||
|
||||
if ( !measurement->kind().isEmpty() )
|
||||
{
|
||||
measurementText += QString( "Kind: %1\n" ).arg( measurement->kind() );
|
||||
}
|
||||
|
||||
if ( measurement->quality() > 0 )
|
||||
{
|
||||
measurementText += QString( "Quality: %1\n" ).arg( measurement->quality() );
|
||||
}
|
||||
|
||||
if ( !measurement->remark().isEmpty() )
|
||||
{
|
||||
measurementText += QString( "Remark: %1\n" ).arg( measurement->remark() );
|
||||
}
|
||||
|
||||
RiuMainWindow::instance()->setResultInfo( measurementText );
|
||||
RiuMainWindow::instance()->selectAsCurrentItem( collection );
|
||||
}
|
||||
}
|
||||
|
||||
if ( dynamic_cast<const RivWellPathSourceInfo*>( firstPickedPart->sourceInfo() ) )
|
||||
|
Loading…
Reference in New Issue
Block a user