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:
@@ -18,6 +18,8 @@
|
||||
#ifndef IMAGEBASE_H
|
||||
#define IMAGEBASE_H
|
||||
|
||||
#include <Mod/Image/ImageGlobal.h>
|
||||
|
||||
namespace Image
|
||||
{
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
#include <App/GeoFeature.h>
|
||||
#include <App/PropertyFile.h>
|
||||
#include <App/PropertyUnits.h>
|
||||
#include <Mod/Image/ImageGlobal.h>
|
||||
|
||||
namespace Image
|
||||
{
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
#else
|
||||
#include "GLImageBox.h"
|
||||
#endif
|
||||
#include <Mod/Image/ImageGlobal.h>
|
||||
|
||||
class QSlider;
|
||||
class QAction;
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
#define IMAGE_ViewProviderImagePlane_H
|
||||
|
||||
#include <Gui/ViewProviderGeometryObject.h>
|
||||
#include <Mod/Image/ImageGlobal.h>
|
||||
|
||||
class SoCoordinate3;
|
||||
class SoDrawStyle;
|
||||
@@ -48,12 +49,12 @@ public:
|
||||
void attach(App::DocumentObject *pcObject);
|
||||
void setDisplayMode(const char* ModeName);
|
||||
std::vector<std::string> getDisplayModes() const;
|
||||
void updateData(const App::Property*);
|
||||
|
||||
private:
|
||||
bool loadSvg(const char*, float x, float y, QImage& img);
|
||||
|
||||
protected:
|
||||
void updateData(const App::Property*);
|
||||
|
||||
private:
|
||||
bool loadSvg(const char*, float x, float y, QImage& img);
|
||||
|
||||
protected:
|
||||
SoCoordinate3 * pcCoords;
|
||||
SoTexture2 * texture;
|
||||
};
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
#define IMAGE_WORKBENCH_H
|
||||
|
||||
#include <Gui/Workbench.h>
|
||||
#include <Mod/Image/ImageGlobal.h>
|
||||
|
||||
namespace ImageGui {
|
||||
|
||||
|
||||
32
src/Mod/Image/ImageGlobal.h
Normal file
32
src/Mod/Image/ImageGlobal.h
Normal file
@@ -0,0 +1,32 @@
|
||||
/***************************************************************************
|
||||
* Copyright (c) Imetric 4D Imaging Sarl *
|
||||
* *
|
||||
* Author: Werner Mayer *
|
||||
* *
|
||||
***************************************************************************/
|
||||
|
||||
#include <FCGlobal.h>
|
||||
|
||||
#ifndef IMAGE_GLOBAL_H
|
||||
#define IMAGE_GLOBAL_H
|
||||
|
||||
|
||||
// Image
|
||||
#ifndef ImageExport
|
||||
#ifdef Image_EXPORTS
|
||||
# define ImageExport FREECAD_DECL_EXPORT
|
||||
#else
|
||||
# define ImageExport FREECAD_DECL_IMPORT
|
||||
#endif
|
||||
#endif
|
||||
|
||||
// ImageGui
|
||||
#ifndef ImageGuiExport
|
||||
#ifdef ImageGui_EXPORTS
|
||||
# define ImageGuiExport FREECAD_DECL_EXPORT
|
||||
#else
|
||||
# define ImageGuiExport FREECAD_DECL_IMPORT
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#endif //IMAGE_GLOBAL_H
|
||||
Reference in New Issue
Block a user