2017-11-29 06:41:13 -06:00
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
//
|
|
|
|
// Copyright (C) 2017 Statoil ASA
|
2019-09-06 03:40:57 -05:00
|
|
|
//
|
2017-11-29 06:41:13 -06:00
|
|
|
// ResInsight is free software: you can redistribute it and/or modify
|
|
|
|
// it under the terms of the GNU General Public License as published by
|
|
|
|
// the Free Software Foundation, either version 3 of the License, or
|
|
|
|
// (at your option) any later version.
|
2019-09-06 03:40:57 -05:00
|
|
|
//
|
2017-11-29 06:41:13 -06:00
|
|
|
// ResInsight is distributed in the hope that it will be useful, but WITHOUT ANY
|
|
|
|
// WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
|
|
// FITNESS FOR A PARTICULAR PURPOSE.
|
2019-09-06 03:40:57 -05:00
|
|
|
//
|
|
|
|
// See the GNU General Public License at <http://www.gnu.org/licenses/gpl.html>
|
2017-11-29 06:41:13 -06:00
|
|
|
// for more details.
|
|
|
|
//
|
|
|
|
/////////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#include "RiuTimeStepChangedHandler.h"
|
2018-03-02 02:31:17 -06:00
|
|
|
|
2022-04-04 05:06:01 -05:00
|
|
|
#include "RiaGuiApplication.h"
|
|
|
|
|
|
|
|
#include "Rim3dView.h"
|
|
|
|
|
2017-11-29 06:41:13 -06:00
|
|
|
#include "RiuMainWindow.h"
|
2018-03-02 02:31:17 -06:00
|
|
|
#include "RiuMohrsCirclePlot.h"
|
2017-11-29 06:41:13 -06:00
|
|
|
#include "RiuPvtPlotPanel.h"
|
|
|
|
#include "RiuPvtPlotUpdater.h"
|
2018-03-02 02:31:17 -06:00
|
|
|
#include "RiuRelativePermeabilityPlotPanel.h"
|
|
|
|
#include "RiuRelativePermeabilityPlotUpdater.h"
|
2017-11-29 06:41:13 -06:00
|
|
|
|
|
|
|
#include "cvfDebugTimer.h"
|
2019-09-06 03:40:57 -05:00
|
|
|
#include "cvfTrace.h"
|
2017-11-29 06:41:13 -06:00
|
|
|
|
|
|
|
//==================================================================================================
|
|
|
|
///
|
|
|
|
/// \class RiuTimeStepChangedHandler
|
|
|
|
///
|
2019-09-06 03:40:57 -05:00
|
|
|
///
|
2017-11-29 06:41:13 -06:00
|
|
|
///
|
|
|
|
//==================================================================================================
|
|
|
|
|
|
|
|
//--------------------------------------------------------------------------------------------------
|
2019-09-06 03:40:57 -05:00
|
|
|
///
|
2017-11-29 06:41:13 -06:00
|
|
|
//--------------------------------------------------------------------------------------------------
|
2020-02-12 04:13:38 -06:00
|
|
|
RiuTimeStepChangedHandler::RiuTimeStepChangedHandler()
|
|
|
|
{
|
|
|
|
}
|
2017-11-29 06:41:13 -06:00
|
|
|
|
|
|
|
//--------------------------------------------------------------------------------------------------
|
2019-09-06 03:40:57 -05:00
|
|
|
///
|
2017-11-29 06:41:13 -06:00
|
|
|
//--------------------------------------------------------------------------------------------------
|
|
|
|
RiuTimeStepChangedHandler* RiuTimeStepChangedHandler::instance()
|
|
|
|
{
|
|
|
|
static RiuTimeStepChangedHandler* singletonInstance = new RiuTimeStepChangedHandler;
|
|
|
|
return singletonInstance;
|
|
|
|
}
|
|
|
|
|
|
|
|
//--------------------------------------------------------------------------------------------------
|
2019-09-06 03:40:57 -05:00
|
|
|
///
|
2017-11-29 06:41:13 -06:00
|
|
|
//--------------------------------------------------------------------------------------------------
|
2019-09-06 03:40:57 -05:00
|
|
|
void RiuTimeStepChangedHandler::handleTimeStepChanged( Rim3dView* changedView ) const
|
2017-11-29 06:41:13 -06:00
|
|
|
{
|
2022-04-04 05:06:01 -05:00
|
|
|
if ( !RiaGuiApplication::isRunning() ) return;
|
2017-11-29 06:41:13 -06:00
|
|
|
|
2023-02-26 03:48:40 -06:00
|
|
|
RiuRelativePermeabilityPlotUpdater* relPermPlotUpdater = RiuMainWindow::instance()->relativePermeabilityPlotPanel()->plotUpdater();
|
2019-09-06 03:40:57 -05:00
|
|
|
relPermPlotUpdater->updateOnTimeStepChanged( changedView );
|
2017-11-29 06:41:13 -06:00
|
|
|
|
|
|
|
RiuPvtPlotUpdater* pvtPlotUpdater = RiuMainWindow::instance()->pvtPlotPanel()->plotUpdater();
|
2019-09-06 03:40:57 -05:00
|
|
|
pvtPlotUpdater->updateOnTimeStepChanged( changedView );
|
2017-11-29 06:41:13 -06:00
|
|
|
|
2018-03-02 02:31:17 -06:00
|
|
|
RiuMohrsCirclePlot* mohrsCirclePlot = RiuMainWindow::instance()->mohrsCirclePlot();
|
2019-09-06 03:40:57 -05:00
|
|
|
if ( mohrsCirclePlot ) mohrsCirclePlot->updateOnTimeStepChanged( changedView );
|
2017-11-29 06:41:13 -06:00
|
|
|
}
|