mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Janitor : Apply clang-format fixes on codebase in ApplicationCode
This commit is contained in:
@@ -55,7 +55,7 @@ bool RiuCadNavigation::handleInputEvent( QInputEvent* inputEvent )
|
||||
|
||||
if ( me->button() == Qt::MidButton && me->modifiers() == Qt::NoModifier && isRotationEnabled() )
|
||||
{
|
||||
this->pickAndSetPointOfInterest(me->x(), me->y());
|
||||
this->pickAndSetPointOfInterest( me->x(), me->y() );
|
||||
|
||||
m_trackball->startNavigation( cvf::ManipulatorTrackball::ROTATE, translatedMousePosX, translatedMousePosY );
|
||||
m_isNavigating = true;
|
||||
|
||||
@@ -68,8 +68,7 @@ bool RiuComparisonViewMover::eventFilter( QObject* watched, QEvent* event )
|
||||
m_viewer->setComparisonViewVisibleNormalizedRect(
|
||||
cvf::Rectf( normMousePos.x(),
|
||||
orgCompViewWindow.min().y(),
|
||||
( orgCompViewWindow.min().x() + orgCompViewWindow.width() ) -
|
||||
normMousePos.x(),
|
||||
( orgCompViewWindow.min().x() + orgCompViewWindow.width() ) - normMousePos.x(),
|
||||
orgCompViewWindow.height() ) );
|
||||
|
||||
return true;
|
||||
|
||||
@@ -55,7 +55,7 @@ bool RiuGeoQuestNavigation::handleInputEvent( QInputEvent* inputEvent )
|
||||
|
||||
if ( me->button() == Qt::LeftButton && isRotationEnabled() )
|
||||
{
|
||||
this->pickAndSetPointOfInterest(me->x(), me->y());
|
||||
this->pickAndSetPointOfInterest( me->x(), me->y() );
|
||||
|
||||
m_trackball->startNavigation( cvf::ManipulatorTrackball::ROTATE, translatedMousePosX, translatedMousePosY );
|
||||
m_isNavigating = true;
|
||||
|
||||
@@ -482,7 +482,7 @@ void RiuGridPlotWindow::dropEvent( QDropEvent* event )
|
||||
|
||||
if ( insertAfter != plotToMove )
|
||||
{
|
||||
m_plotDefinition->movePlotsToThis( { plotToMove }, insertAfter );
|
||||
m_plotDefinition->movePlotsToThis( {plotToMove}, insertAfter );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -574,7 +574,7 @@ void RiuPlotMainWindow::updateGridPlotWindowToolBar()
|
||||
RimGridPlotWindow* plotWindow = dynamic_cast<RimGridPlotWindow*>( m_activePlotViewWindow.p() );
|
||||
if ( plotWindow )
|
||||
{
|
||||
std::vector<caf::PdmFieldHandle*> toolBarFields = { plotWindow->columnCountField() };
|
||||
std::vector<caf::PdmFieldHandle*> toolBarFields = {plotWindow->columnCountField()};
|
||||
m_gridPlotWindowToolBarEditor->setFields( toolBarFields );
|
||||
m_gridPlotWindowToolBarEditor->updateUi();
|
||||
m_gridPlotWindowToolBarEditor->show();
|
||||
|
||||
@@ -75,7 +75,7 @@ void RiuQwtPlotTools::setCommonPlotBehaviour( QwtPlot* plot )
|
||||
plot->setAxisFont( QwtPlot::yRight, axisFont );
|
||||
|
||||
// Axis title font
|
||||
std::vector<QwtPlot::Axis> axes = { QwtPlot::xBottom, QwtPlot::xTop, QwtPlot::yLeft, QwtPlot::yRight };
|
||||
std::vector<QwtPlot::Axis> axes = {QwtPlot::xBottom, QwtPlot::xTop, QwtPlot::yLeft, QwtPlot::yRight};
|
||||
|
||||
for ( QwtPlot::Axis axis : axes )
|
||||
{
|
||||
@@ -139,14 +139,14 @@ void RiuQwtPlotTools::enableDateBasedBottomXAxis( QwtPlot*
|
||||
{
|
||||
QwtDateScaleDraw* scaleDraw = new QwtDateScaleDraw( Qt::UTC );
|
||||
|
||||
std::set<QwtDate::IntervalType> intervals = { QwtDate::Year,
|
||||
QwtDate::Month,
|
||||
QwtDate::Week,
|
||||
QwtDate::Day,
|
||||
QwtDate::Hour,
|
||||
QwtDate::Minute,
|
||||
QwtDate::Second,
|
||||
QwtDate::Millisecond };
|
||||
std::set<QwtDate::IntervalType> intervals = {QwtDate::Year,
|
||||
QwtDate::Month,
|
||||
QwtDate::Week,
|
||||
QwtDate::Day,
|
||||
QwtDate::Hour,
|
||||
QwtDate::Minute,
|
||||
QwtDate::Second,
|
||||
QwtDate::Millisecond};
|
||||
|
||||
for ( QwtDate::IntervalType interval : intervals )
|
||||
{
|
||||
|
||||
@@ -647,7 +647,7 @@ RiuWidgetStyleSheet RiuQwtPlotWidget::createCanvasStyleSheet() const
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RiuQwtPlotWidget::setDefaults()
|
||||
{
|
||||
setEnabledAxes( { QwtPlot::xTop, QwtPlot::yLeft } );
|
||||
setEnabledAxes( {QwtPlot::xTop, QwtPlot::yLeft} );
|
||||
RiuQwtPlotTools::setCommonPlotBehaviour( this );
|
||||
}
|
||||
|
||||
@@ -789,7 +789,7 @@ void RiuQwtPlotWidget::highlightCurve( const QwtPlotCurve* closestCurve )
|
||||
symbol->setPen( blendedSymbolLineColor, symbol->pen().width(), symbol->pen().style() );
|
||||
}
|
||||
}
|
||||
CurveColors curveColors = { curveColor, symbolColor, symbolLineColor };
|
||||
CurveColors curveColors = {curveColor, symbolColor, symbolLineColor};
|
||||
m_originalCurveColors.insert( std::make_pair( plotCurve, curveColors ) );
|
||||
m_originalCurveColors.insert( std::make_pair( plotCurve, curveColors ) );
|
||||
m_originalZValues.insert( std::make_pair( plotCurve, zValue ) );
|
||||
|
||||
@@ -55,7 +55,7 @@ bool RiuRmsNavigation::handleInputEvent( QInputEvent* inputEvent )
|
||||
|
||||
if ( me->button() == Qt::MidButton && isRotationEnabled() )
|
||||
{
|
||||
this->pickAndSetPointOfInterest(me->x(), me->y());
|
||||
this->pickAndSetPointOfInterest( me->x(), me->y() );
|
||||
|
||||
m_trackball->startNavigation( cvf::ManipulatorTrackball::ROTATE, translatedMousePosX, translatedMousePosY );
|
||||
m_isNavigating = true;
|
||||
|
||||
@@ -92,55 +92,55 @@ private:
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RiuSummaryCurveDefSelection::RiuSummaryCurveDefSelection()
|
||||
: m_identifierFieldsMap( {
|
||||
{ RifEclipseSummaryAddress::SUMMARY_FIELD,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_AQUIFER,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_AQUIFER_NUMBER ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_NETWORK,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_MISC,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_REGION,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_REGION_NUMBER ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_REGION_2_REGION,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_REGION_2_REGION ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_WELL_GROUP,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_WELL_GROUP_NAME ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_WELL,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_WELL_NAME ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_WELL_COMPLETION,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_WELL_NAME ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_CELL_IJK ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_WELL_COMPLETION_LGR,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_LGR_NAME ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_WELL_NAME ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_CELL_IJK ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_WELL_LGR,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_LGR_NAME ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_WELL_NAME ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_WELL_SEGMENT,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_WELL_NAME ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_SEGMENT_NUMBER ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_BLOCK,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_CELL_IJK ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_BLOCK_LGR,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_LGR_NAME ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_CELL_IJK ) },
|
||||
{ new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_CALCULATED,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{ RifEclipseSummaryAddress::SUMMARY_IMPORTED,
|
||||
{ { new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME ) } } },
|
||||
{RifEclipseSummaryAddress::SUMMARY_FIELD,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_AQUIFER,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_AQUIFER_NUMBER )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_NETWORK,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_MISC,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_REGION,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_REGION_NUMBER )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_REGION_2_REGION,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_REGION_2_REGION )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_WELL_GROUP,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_WELL_GROUP_NAME )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_WELL,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_WELL_NAME )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_WELL_COMPLETION,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_WELL_NAME )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_CELL_IJK )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_WELL_COMPLETION_LGR,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_LGR_NAME )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_WELL_NAME )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_CELL_IJK )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_WELL_LGR,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_LGR_NAME )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_WELL_NAME )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_WELL_SEGMENT,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_WELL_NAME )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_SEGMENT_NUMBER )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_BLOCK,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_CELL_IJK )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_BLOCK_LGR,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_LGR_NAME )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_CELL_IJK )},
|
||||
{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_CALCULATED,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
{RifEclipseSummaryAddress::SUMMARY_IMPORTED,
|
||||
{{new SummaryIdentifierAndField( RifEclipseSummaryAddress::INPUT_VECTOR_NAME )}}},
|
||||
} )
|
||||
{
|
||||
CAF_PDM_InitFieldNoDefault( &m_selectedSources, "SummaryCases", "Cases", "", "", "" );
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -182,7 +182,7 @@ RiuViewer::RiuViewer( const QGLFormat& format, QWidget* parent )
|
||||
m_scaleLegend->setOrientation( caf::OverlayScaleLegend::HORIZONTAL );
|
||||
|
||||
m_comparisonWindowMover = new RiuComparisonViewMover( this );
|
||||
this->setComparisonViewToFollowAnimation(false);
|
||||
this->setComparisonViewToFollowAnimation( false );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -313,7 +313,7 @@ void RiuViewer::slotSetCurrentFrame( int frameIndex )
|
||||
|
||||
// Update views using this as comparison
|
||||
Rim3dView* view = dynamic_cast<Rim3dView*>( m_rimView.p() );
|
||||
if (view)
|
||||
if ( view )
|
||||
{
|
||||
std::set<Rim3dView*> containingViews = view->viewsUsingThisAsComparisonView();
|
||||
|
||||
@@ -356,7 +356,7 @@ void RiuViewer::setOwnerReservoirView( RiuViewerToViewInterface* owner )
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RiuViewer::paintOverlayItems( QPainter* painter )
|
||||
{
|
||||
// Update the legend layout on every redraw as the legends stores their own position,
|
||||
// Update the legend layout on every redraw as the legends stores their own position,
|
||||
// and when they are shared between views the positions are overwritten.
|
||||
updateLegendLayout();
|
||||
|
||||
@@ -987,7 +987,7 @@ void RiuViewer::setAxisLabels( const cvf::String& xLabel, const cvf::String& yLa
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RiuViewerCommands* RiuViewer::viewerCommands() const
|
||||
{
|
||||
|
||||
@@ -1356,15 +1356,15 @@ void RiuViewerCommands::handleTextPicking( int winPosX, int winPosY, cvf::HitIte
|
||||
{
|
||||
for ( size_t pIdx = 0; pIdx < partCollection.size(); ++pIdx )
|
||||
{
|
||||
DrawableText* textDrawable = dynamic_cast<DrawableText*>(partCollection[pIdx]->drawable());
|
||||
DrawableText* textDrawable = dynamic_cast<DrawableText*>( partCollection[pIdx]->drawable() );
|
||||
if ( textDrawable )
|
||||
{
|
||||
cvf::Vec3d ppoint;
|
||||
if ( textDrawable->rayIntersect(*ray, *(m_viewer->mainCamera()), &ppoint) )
|
||||
if ( textDrawable->rayIntersect( *ray, *( m_viewer->mainCamera() ), &ppoint ) )
|
||||
{
|
||||
cvf::ref<HitItem> hitItem = new HitItem(0, ppoint);
|
||||
hitItem->setPart(partCollection[pIdx].p());
|
||||
hitItems->add(hitItem.p());
|
||||
cvf::ref<HitItem> hitItem = new HitItem( 0, ppoint );
|
||||
hitItem->setPart( partCollection[pIdx].p() );
|
||||
hitItems->add( hitItem.p() );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user