Base: split export/import macros from FCConfig.h and move them to FCGlobal.h
The FCGlobal.h can be included in a Global.h header file of an extension module. The reason is that some IDEs (e.g. QtCreator) fails to detect the export/import macros when only defined in the PreCompiled.h files and thus raise a parser warning.
This commit is contained in:
@@ -28,6 +28,9 @@
|
||||
#include <Mod/Mesh/App/WildMagic4/Wm4QuadricSurface.h>
|
||||
#include <Mod/Mesh/App/WildMagic4/Wm4Eigen.h>
|
||||
#include <Mod/Mesh/App/WildMagic4/Wm4ImplicitSurface.h>
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
#include <algorithm>
|
||||
#include <list>
|
||||
#include <set>
|
||||
|
||||
@@ -24,6 +24,10 @@
|
||||
#ifndef MESH_DEFINITIONS_H
|
||||
#define MESH_DEFINITIONS_H
|
||||
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
|
||||
// default values
|
||||
#define MESH_MIN_PT_DIST 1.0e-6f
|
||||
#define MESH_MIN_EDGE_LEN 1.0e-3f
|
||||
|
||||
@@ -24,6 +24,10 @@
|
||||
#ifndef VISITOR_H
|
||||
#define VISITOR_H
|
||||
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
|
||||
namespace MeshCore {
|
||||
|
||||
class MeshFacet;
|
||||
|
||||
@@ -27,6 +27,9 @@
|
||||
#include <App/DocumentObject.h>
|
||||
#include <App/PropertyStandard.h>
|
||||
#include <App/PropertyLinks.h>
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
|
||||
namespace Mesh
|
||||
{
|
||||
|
||||
@@ -24,10 +24,13 @@
|
||||
#ifndef MESH_MESHPOINT_H
|
||||
#define MESH_MESHPOINT_H
|
||||
|
||||
#include <climits>
|
||||
#include <Base/Matrix.h>
|
||||
#include <Base/Vector3D.h>
|
||||
|
||||
#include "Mesh.h"
|
||||
#include <Base/Handle.h>
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
|
||||
using Base::Vector3d;
|
||||
|
||||
@@ -59,4 +62,4 @@ public:
|
||||
} // namespace Mesh
|
||||
|
||||
|
||||
#endif // MESH_MESH_H
|
||||
#endif // MESH_MESHPOINT_H
|
||||
|
||||
@@ -24,6 +24,9 @@
|
||||
#ifndef MESHGUI_DLGSETTINGSIMPORTEXPORTIMP_H
|
||||
#define MESHGUI_DLGSETTINGSIMPORTEXPORTIMP_H
|
||||
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
#include <Gui/PropertyPage.h>
|
||||
|
||||
namespace MeshGui {
|
||||
|
||||
@@ -24,6 +24,9 @@
|
||||
#ifndef MESHGUI_DLGSETTINGSMESHVIEW_H
|
||||
#define MESHGUI_DLGSETTINGSMESHVIEW_H
|
||||
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
#include <Gui/PropertyPage.h>
|
||||
#include <memory>
|
||||
|
||||
|
||||
@@ -27,6 +27,9 @@
|
||||
#include <QDialog>
|
||||
#include <Gui/TaskView/TaskDialog.h>
|
||||
#include <Gui/TaskView/TaskView.h>
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
|
||||
class QButtonGroup;
|
||||
|
||||
|
||||
@@ -30,6 +30,9 @@
|
||||
#include <Gui/SelectionObject.h>
|
||||
#include <Gui/TaskView/TaskDialog.h>
|
||||
#include <Gui/TaskView/TaskView.h>
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
|
||||
namespace Gui {
|
||||
class View3DInventorViewer;
|
||||
|
||||
@@ -24,6 +24,9 @@
|
||||
#define MESHGUI_PROPERTYEDITOR_MESH_H
|
||||
|
||||
#include <Gui/propertyeditor/PropertyItem.h>
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
|
||||
namespace MeshGui {
|
||||
|
||||
|
||||
@@ -27,6 +27,9 @@
|
||||
#include <QWidget>
|
||||
#include <Gui/TaskView/TaskDialog.h>
|
||||
#include <Gui/TaskView/TaskView.h>
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
|
||||
// forward declarations
|
||||
namespace Mesh { class Feature; }
|
||||
|
||||
@@ -28,6 +28,9 @@
|
||||
#include <Inventor/engines/SoSubEngine.h>
|
||||
#include <Inventor/fields/SoSFBool.h>
|
||||
#include <Inventor/fields/SoMFColor.h>
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
|
||||
class SoGLCoordinateElement;
|
||||
class SoTextureCoordinateBundle;
|
||||
|
||||
@@ -30,6 +30,9 @@
|
||||
#include <Inventor/nodes/SoSubNode.h>
|
||||
#include <Inventor/nodes/SoShape.h>
|
||||
#include <Inventor/elements/SoReplacedElement.h>
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
|
||||
namespace MeshGui {
|
||||
|
||||
|
||||
@@ -24,6 +24,9 @@
|
||||
#ifndef MESH_WORKBENCH_H
|
||||
#define MESH_WORKBENCH_H
|
||||
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#include <Mod/Mesh/MeshGlobal.h>
|
||||
#endif
|
||||
#include <Gui/Workbench.h>
|
||||
|
||||
namespace MeshGui {
|
||||
|
||||
47
src/Mod/Mesh/MeshGlobal.h
Normal file
47
src/Mod/Mesh/MeshGlobal.h
Normal file
@@ -0,0 +1,47 @@
|
||||
/***************************************************************************
|
||||
* Copyright (c) 2019 Werner Mayer <wmayer[at]users.sourceforge.net> *
|
||||
* *
|
||||
* This file is part of the FreeCAD CAx development system. *
|
||||
* *
|
||||
* This library is free software; you can redistribute it and/or *
|
||||
* modify it under the terms of the GNU Library General Public *
|
||||
* License as published by the Free Software Foundation; either *
|
||||
* version 2 of the License, or (at your option) any later version. *
|
||||
* *
|
||||
* This library 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 Library General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU Library General Public *
|
||||
* License along with this library; see the file COPYING.LIB. If not, *
|
||||
* write to the Free Software Foundation, Inc., 59 Temple Place, *
|
||||
* Suite 330, Boston, MA 02111-1307, USA *
|
||||
* *
|
||||
***************************************************************************/
|
||||
|
||||
#include <FCGlobal.h>
|
||||
|
||||
#ifndef MESH_GLOBAL_H
|
||||
#define MESH_GLOBAL_H
|
||||
|
||||
|
||||
// Mesh
|
||||
#ifndef MeshExport
|
||||
#ifdef Mesh_EXPORTS
|
||||
# define MeshExport FREECAD_DECL_EXPORT
|
||||
#else
|
||||
# define MeshExport FREECAD_DECL_IMPORT
|
||||
#endif
|
||||
#endif
|
||||
|
||||
// MeshGui
|
||||
#ifndef MeshGuiExport
|
||||
#ifdef MeshGui_EXPORTS
|
||||
# define MeshGuiExport FREECAD_DECL_EXPORT
|
||||
#else
|
||||
# define MeshGuiExport FREECAD_DECL_IMPORT
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#endif //MESH_GLOBAL_H
|
||||
Reference in New Issue
Block a user