mirror of
https://github.com/OPM/ResInsight.git
synced 2025-01-07 14:43:10 -06:00
#3452 Command execution. Clear cached data before executing new commands
This commit is contained in:
parent
273c2912ae
commit
ce26437130
@ -61,6 +61,8 @@ void RicfCommandFileExecutor::executeCommands(QTextStream& stream)
|
||||
RicfMessages messages;
|
||||
std::vector<RicfCommandObject*> executableCommands;
|
||||
{
|
||||
clearCachedData();
|
||||
|
||||
std::vector<RicfCommandObject*> fileCommands = RicfCommandFileReader::readCommands(stream, caf::PdmDefaultObjectFactory::instance(), &messages);
|
||||
for (auto message : messages.m_messages)
|
||||
{
|
||||
@ -214,3 +216,12 @@ std::vector<RicfCommandObject*> RicfCommandFileExecutor::prepareFileCommandsForE
|
||||
|
||||
return executableCommands;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RicfCommandFileExecutor::clearCachedData()
|
||||
{
|
||||
m_exportPaths.clear();
|
||||
m_lastProjectPath.clear();
|
||||
}
|
||||
|
@ -60,6 +60,8 @@ public:
|
||||
static std::vector<RicfCommandObject*> prepareFileCommandsForExecution(const std::vector<RicfCommandObject*>& commandsReadFromFile);
|
||||
|
||||
private:
|
||||
void clearCachedData();
|
||||
|
||||
std::map<ExportType, QString> m_exportPaths;
|
||||
QString m_lastProjectPath;
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user