From c5fc0d34e4722374675a5a8019956e96be35c96a Mon Sep 17 00:00:00 2001 From: Magne Sjaastad Date: Sun, 11 Nov 2018 14:07:42 +0100 Subject: [PATCH] Whitespace --- .../RicfExportVisibleCells.cpp | 53 ++++++++++--------- .../RicfExportVisibleCells.h | 26 +++++---- 2 files changed, 43 insertions(+), 36 deletions(-) diff --git a/ApplicationCode/CommandFileInterface/RicfExportVisibleCells.cpp b/ApplicationCode/CommandFileInterface/RicfExportVisibleCells.cpp index 5ba1c52eba..ecd1d4c6de 100644 --- a/ApplicationCode/CommandFileInterface/RicfExportVisibleCells.cpp +++ b/ApplicationCode/CommandFileInterface/RicfExportVisibleCells.cpp @@ -1,17 +1,17 @@ ///////////////////////////////////////////////////////////////////////////////// // // Copyright (C) 2017 Statoil ASA -// +// // 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. -// +// // 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. -// -// See the GNU General Public License at +// +// See the GNU General Public License at // for more details. // ///////////////////////////////////////////////////////////////////////////////// @@ -21,20 +21,20 @@ #include "RiaFilePathTools.h" #include "RiaViewRedrawScheduler.h" -#include "RicfApplicationTools.h" -#include "RicfCommandFileExecutor.h" #include "ExportCommands/RicSaveEclipseInputVisibleCellsFeature.h" #include "ExportCommands/RicSaveEclipseInputVisibleCellsUi.h" +#include "RicfApplicationTools.h" +#include "RicfCommandFileExecutor.h" #include "RiaApplication.h" #include "RiaLogging.h" -#include "RimProject.h" -#include "RimOilField.h" -#include "RimEclipseCaseCollection.h" #include "RimEclipseCase.h" -#include "RimEclipseView.h" +#include "RimEclipseCaseCollection.h" #include "RimEclipseCellColors.h" +#include "RimEclipseView.h" +#include "RimOilField.h" +#include "RimProject.h" #include "RifEclipseInputFileTools.h" @@ -48,31 +48,32 @@ CAF_PDM_SOURCE_INIT(RicfExportVisibleCells, "exportVisibleCells"); namespace caf { - template<> - void AppEnum< RicfExportVisibleCells::ExportKeyword >::setUp() - { - addItem(RicfExportVisibleCells::FLUXNUM, "FLUXNUM", "FLUXNUM"); - addItem(RicfExportVisibleCells::MULTNUM, "MULTNUM", "MULTNUM"); +template<> +void AppEnum::setUp() +{ + addItem(RicfExportVisibleCells::FLUXNUM, "FLUXNUM", "FLUXNUM"); + addItem(RicfExportVisibleCells::MULTNUM, "MULTNUM", "MULTNUM"); - setDefault(RicfExportVisibleCells::FLUXNUM); - } + setDefault(RicfExportVisibleCells::FLUXNUM); } +} // namespace caf //-------------------------------------------------------------------------------------------------- -/// +/// //-------------------------------------------------------------------------------------------------- RicfExportVisibleCells::RicfExportVisibleCells() { RICF_InitField(&m_caseId, "caseId", -1, "Case ID", "", "", ""); RICF_InitField(&m_viewName, "viewName", QString(), "View Name", "", "", ""); - RICF_InitField(&m_exportKeyword, "exportKeyword", caf::AppEnum(), "Export Keyword", "", "", ""); + RICF_InitField( + &m_exportKeyword, "exportKeyword", caf::AppEnum(), "Export Keyword", "", "", ""); RICF_InitField(&m_visibleActiveCellsValue, "visibleActiveCellsValue", 1, "Visible Active Cells Value", "", "", ""); RICF_InitField(&m_hiddenActiveCellsValue, "hiddenActiveCellsValue", 0, "Hidden Active Cells Value", "", "", ""); RICF_InitField(&m_inactiveCellsValue, "inactiveCellsValue", 0, "Inactive Cells Value", "", "", ""); } //-------------------------------------------------------------------------------------------------- -/// +/// //-------------------------------------------------------------------------------------------------- void RicfExportVisibleCells::execute() { @@ -103,17 +104,19 @@ void RicfExportVisibleCells::execute() } //-------------------------------------------------------------------------------------------------- -/// +/// //-------------------------------------------------------------------------------------------------- void RicfExportVisibleCells::buildExportSettings(const QString& exportFolder, RicSaveEclipseInputVisibleCellsUi* exportSettings) { QDir baseDir(exportFolder); exportSettings->exportFilename = baseDir.absoluteFilePath(QString("%1.grdecl").arg(m_exportKeyword().text())); - if (m_exportKeyword == ExportKeyword::FLUXNUM) exportSettings->exportKeyword = RicSaveEclipseInputVisibleCellsUi::FLUXNUM; - else if (m_exportKeyword == ExportKeyword::MULTNUM) exportSettings->exportKeyword = RicSaveEclipseInputVisibleCellsUi::MULTNUM; + if (m_exportKeyword == ExportKeyword::FLUXNUM) + exportSettings->exportKeyword = RicSaveEclipseInputVisibleCellsUi::FLUXNUM; + else if (m_exportKeyword == ExportKeyword::MULTNUM) + exportSettings->exportKeyword = RicSaveEclipseInputVisibleCellsUi::MULTNUM; exportSettings->visibleActiveCellsValue = m_visibleActiveCellsValue; - exportSettings->hiddenActiveCellsValue = m_hiddenActiveCellsValue; - exportSettings->inactiveCellsValue = m_inactiveCellsValue; + exportSettings->hiddenActiveCellsValue = m_hiddenActiveCellsValue; + exportSettings->inactiveCellsValue = m_inactiveCellsValue; } diff --git a/ApplicationCode/CommandFileInterface/RicfExportVisibleCells.h b/ApplicationCode/CommandFileInterface/RicfExportVisibleCells.h index 03b9c5020d..e5bb4986e9 100644 --- a/ApplicationCode/CommandFileInterface/RicfExportVisibleCells.h +++ b/ApplicationCode/CommandFileInterface/RicfExportVisibleCells.h @@ -1,17 +1,17 @@ ///////////////////////////////////////////////////////////////////////////////// // // Copyright (C) 2017 Statoil ASA -// +// // 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. -// +// // 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. -// -// See the GNU General Public License at +// +// See the GNU General Public License at // for more details. // ///////////////////////////////////////////////////////////////////////////////// @@ -36,7 +36,11 @@ class RicfExportVisibleCells : public RicfCommandObject { CAF_PDM_HEADER_INIT; - enum ExportKeyword {FLUXNUM, MULTNUM}; + enum ExportKeyword + { + FLUXNUM, + MULTNUM + }; public: RicfExportVisibleCells(); @@ -46,10 +50,10 @@ public: private: void buildExportSettings(const QString& exportFolder, RicSaveEclipseInputVisibleCellsUi* exportSettings); - caf::PdmField m_caseId; - caf::PdmField m_viewName; - caf::PdmField> m_exportKeyword; - caf::PdmField m_visibleActiveCellsValue; - caf::PdmField m_hiddenActiveCellsValue; - caf::PdmField m_inactiveCellsValue; + caf::PdmField m_caseId; + caf::PdmField m_viewName; + caf::PdmField> m_exportKeyword; + caf::PdmField m_visibleActiveCellsValue; + caf::PdmField m_hiddenActiveCellsValue; + caf::PdmField m_inactiveCellsValue; };