From 5fb854036de07ad1e0e27c682b214827f583f932 Mon Sep 17 00:00:00 2001 From: scrawl Date: Tue, 7 Mar 2017 00:34:25 +0100 Subject: [PATCH] Use a forward declaration to avoid having to workaround Qt MOC Don't think that guard was still needed, but a forward declaration is better anyways. --- apps/opencs/view/render/cell.cpp | 5 ++++ apps/opencs/view/render/cell.hpp | 23 ++++++++++--------- .../view/render/pagedworldspacewidget.cpp | 1 + .../view/render/unpagedworldspacewidget.cpp | 1 + 4 files changed, 19 insertions(+), 11 deletions(-) diff --git a/apps/opencs/view/render/cell.cpp b/apps/opencs/view/render/cell.cpp index adc038836..9ba5eeb01 100644 --- a/apps/opencs/view/render/cell.cpp +++ b/apps/opencs/view/render/cell.cpp @@ -9,6 +9,7 @@ #include #include #include +#include #include "../../model/world/idtable.hpp" #include "../../model/world/columns.hpp" @@ -17,9 +18,13 @@ #include "../../model/world/cellcoordinates.hpp" #include "cellwater.hpp" +#include "cellborder.hpp" +#include "cellarrow.hpp" +#include "cellmarker.hpp" #include "mask.hpp" #include "pathgrid.hpp" #include "terrainstorage.hpp" +#include "object.hpp" bool CSVRender::Cell::removeObject (const std::string& id) { diff --git a/apps/opencs/view/render/cell.hpp b/apps/opencs/view/render/cell.hpp index c89c1517f..e8e0d2c63 100644 --- a/apps/opencs/view/render/cell.hpp +++ b/apps/opencs/view/render/cell.hpp @@ -6,18 +6,9 @@ #include #include -#include - #include -#ifndef Q_MOC_RUN -#include -#endif - -#include "object.hpp" -#include "cellarrow.hpp" -#include "cellmarker.hpp" -#include "cellborder.hpp" +#include "../../model/world/cellcoordinates.hpp" class QModelIndex; @@ -31,7 +22,11 @@ namespace osg namespace CSMWorld { class Data; - class CellCoordinates; +} + +namespace Terrain +{ + class TerrainGrid; } namespace CSVRender @@ -39,6 +34,12 @@ namespace CSVRender class CellWater; class Pathgrid; class TagBase; + class Object; + + class CellArrow; + class CellBorder; + class CellMarker; + class CellWater; class Cell { diff --git a/apps/opencs/view/render/pagedworldspacewidget.cpp b/apps/opencs/view/render/pagedworldspacewidget.cpp index 901dadc85..e855f7e41 100644 --- a/apps/opencs/view/render/pagedworldspacewidget.cpp +++ b/apps/opencs/view/render/pagedworldspacewidget.cpp @@ -20,6 +20,7 @@ #include "editmode.hpp" #include "mask.hpp" #include "cameracontroller.hpp" +#include "cellarrow.hpp" bool CSVRender::PagedWorldspaceWidget::adjustCells() { diff --git a/apps/opencs/view/render/unpagedworldspacewidget.cpp b/apps/opencs/view/render/unpagedworldspacewidget.cpp index 03a97bf1a..de999db0f 100644 --- a/apps/opencs/view/render/unpagedworldspacewidget.cpp +++ b/apps/opencs/view/render/unpagedworldspacewidget.cpp @@ -16,6 +16,7 @@ #include "../widget/scenetooltoggle2.hpp" #include "mask.hpp" +#include "tagbase.hpp" void CSVRender::UnpagedWorldspaceWidget::update() {