Build doesn't work, if include this headers on Windows.

--HG--
branch : DialogTools
This commit is contained in:
dismine 2014-05-31 13:00:19 +04:00
parent cc7f257081
commit 42091c2611
16 changed files with 68 additions and 44 deletions

View File

@ -29,6 +29,9 @@
#include "dialogaboutapp.h" #include "dialogaboutapp.h"
#include "ui_dialogaboutapp.h" #include "ui_dialogaboutapp.h"
#include "../../version.h" #include "../../version.h"
#include <QDate>
#include <QDesktopServices>
#include <QMessageBox>
DialogAboutApp::DialogAboutApp(QWidget *parent) : DialogAboutApp::DialogAboutApp(QWidget *parent) :
QDialog(parent), QDialog(parent),

View File

@ -31,6 +31,7 @@
#include <QSpacerItem> #include <QSpacerItem>
#include <QGridLayout> #include <QGridLayout>
#include "../options.h" #include "../options.h"
#include <QApplication>
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
VException::VException(const QString &what):QException(), what(what), moreInfo(QString()) VException::VException(const QString &what):QException(), what(what), moreInfo(QString())

View File

@ -30,6 +30,7 @@
#include "vspline.h" #include "vspline.h"
#include "../exception/vexception.h" #include "../exception/vexception.h"
#include <QDebug> #include <QDebug>
#include <QtMath>
class QRectF; class QRectF;

View File

@ -27,8 +27,8 @@
*************************************************************************/ *************************************************************************/
#include "vspline.h" #include "vspline.h"
#include <QDebug> #include <QDebug>
#include <QtMath>
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
VSpline::VSpline() VSpline::VSpline()

View File

@ -36,7 +36,7 @@
#include <csignal> #include <csignal>
#ifdef Q_OS_WIN32 #ifdef Q_OS_WIN32
#include WinBase.h #include <Windows.h>
#endif /*Q_OS_WIN32*/ #endif /*Q_OS_WIN32*/
#define SceneSize 50000 #define SceneSize 50000
@ -305,15 +305,30 @@ extern const QString in_Oprt;
*/ */
#ifndef QT_NO_DEBUG #ifndef QT_NO_DEBUG
#ifdef Q_OS_WIN32 #ifdef Q_OS_WIN32
#ifdef Q_CC_MSVC
#define SCASSERT(cond) \ #define SCASSERT(cond) \
{ \ { \
if (!(cond)) \ if (!(cond)) \
{ \ { \
qDebug("ASSERT: %s in %s (%s:%u)", \ qDebug("ASSERT: %s in %s (%s:%u)", \
#cond, __FUNCSIG__, __FILE__, __LINE__); \ #cond, __FUNCSIG__, __FILE__, __LINE__); \
void WINAPI DebugBreak(void); \ \ DebugBreak(); \
} \ } \
} } \
#else
#define SCASSERT(cond) \
{ \
if (!(cond)) \
{ \
qDebug("ASSERT: %s in %s (%s:%u)", \
#cond, __PRETTY_FUNCTION__, __FILE__, __LINE__);\
DebugBreak(); \
} \
} \
#endif /*Q_CC_MSVC*/
#else #else
#define SCASSERT(cond) \ #define SCASSERT(cond) \
{ \ { \
@ -323,7 +338,8 @@ extern const QString in_Oprt;
#cond, __PRETTY_FUNCTION__, __FILE__, __LINE__);\ #cond, __PRETTY_FUNCTION__, __FILE__, __LINE__);\
std::raise(SIGTRAP); \ std::raise(SIGTRAP); \
} \ } \
} } \
#endif /* Q_OS_WIN32 */ #endif /* Q_OS_WIN32 */
#endif /* QT_NO_DEBUG */ #endif /* QT_NO_DEBUG */

View File

@ -36,9 +36,6 @@
#if defined __cplusplus #if defined __cplusplus
/* Add C++ includes here */ /* Add C++ includes here */
#ifdef Q_CC_MSVC
#define _USE_MATH_DEFINES
#endif
#ifdef QT_CORE_LIB #ifdef QT_CORE_LIB
# include <QtCore> # include <QtCore>
@ -64,6 +61,8 @@
# include <QtPrintSupport> # include <QtPrintSupport>
#endif #endif
//Build doesn't work, if include this headers on Windows.
#ifndef Q_OS_WIN
# ifdef QT_XMLPATTERNS_LIB # ifdef QT_XMLPATTERNS_LIB
# include <QtXmlPatterns> # include <QtXmlPatterns>
# endif # endif
@ -71,7 +70,8 @@
# ifdef QT_NETWORK_LIB # ifdef QT_NETWORK_LIB
# include <QtNetwork> # include <QtNetwork>
# endif # endif
#endif /*Q_OS_WIN*/
#endif #endif /*__cplusplus*/
#endif // STABLE_H #endif // STABLE_H

View File

@ -30,9 +30,9 @@
#define VDRAWTOOL_H #define VDRAWTOOL_H
#include "../vabstracttool.h" #include "../vabstracttool.h"
#include <QMenu> #include <QMenu>
#include <QGraphicsSceneContextMenuEvent> #include <QGraphicsSceneContextMenuEvent>
#include <QGraphicsView>
#include "../../dialogs/tools/dialogtool.h" #include "../../dialogs/tools/dialogtool.h"
/** /**

View File

@ -32,6 +32,7 @@
#include <QKeyEvent> #include <QKeyEvent>
#include <QGraphicsSceneMouseEvent> #include <QGraphicsSceneMouseEvent>
#include <QMenu> #include <QMenu>
#include <QGraphicsView>
const QString VToolDetail::TagName = QStringLiteral("detail"); const QString VToolDetail::TagName = QStringLiteral("detail");
const QString VToolDetail::TagNode = QStringLiteral("node"); const QString VToolDetail::TagNode = QStringLiteral("node");

View File

@ -37,8 +37,8 @@
#include <QDebug> #include <QDebug>
#include <QDir> #include <QDir>
#include <QSettings> #include <QSettings>
#include <container/calculator.h> #include <container/calculator.h>
#include <QtMath>
const qreal VApplication::PrintDPI = 96.0; const qreal VApplication::PrintDPI = 96.0;

View File

@ -28,6 +28,7 @@
#include "vsimplespline.h" #include "vsimplespline.h"
#include "../widgets/vapplication.h" #include "../widgets/vapplication.h"
#include <QGraphicsSceneMouseEvent>
#include <QPen> #include <QPen>
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------

View File

@ -23,6 +23,7 @@
#include "qmuparserbase.h" #include "qmuparserbase.h"
#include <QTextStream> #include <QTextStream>
#include <QtMath> #include <QtMath>
#include <QDebug>
#ifdef QMUP_USE_OPENMP #ifdef QMUP_USE_OPENMP
#include <omp.h> #include <omp.h>
#endif #endif
@ -2086,4 +2087,17 @@ void QmuParserBase::Eval(qreal *results, int nBulkSize) const
} }
#endif #endif
} }
//---------------------------------------------------------------------------------------------------------------------
/**
* @brief Set a function that can create variable pointer for unknown expression variables.
* @param a_pFactory A pointer to the variable factory.
* @param pUserData A user defined context pointer.
*/
// cppcheck-suppress unusedFunction
void qmu::QmuParserBase::SetVarFactory(facfun_type a_pFactory, void *pUserData)
{
m_pTokenReader->SetVarCreator(a_pFactory, pUserData);
}
} // namespace qmu } // namespace qmu

View File

@ -284,18 +284,6 @@ inline void QmuParserBase::AddValIdent(identfun_type a_pCallback)
m_pTokenReader->AddValIdent(a_pCallback); m_pTokenReader->AddValIdent(a_pCallback);
} }
//---------------------------------------------------------------------------------------------------------------------
/**
* @brief Set a function that can create variable pointer for unknown expression variables.
* @param a_pFactory A pointer to the variable factory.
* @param pUserData A user defined context pointer.
*/
// cppcheck-suppress unusedFunction
inline void QmuParserBase::SetVarFactory(facfun_type a_pFactory, void *pUserData)
{
m_pTokenReader->SetVarCreator(a_pFactory, pUserData);
}
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------
/** /**
* @brief Get the default symbols used for the built in operators. * @brief Get the default symbols used for the built in operators.
@ -306,11 +294,13 @@ inline const QStringList &QmuParserBase::GetOprtDef()
return c_DefaultOprt; return c_DefaultOprt;
} }
//---------------------------------------------------------------------------------------------------------------------
inline QMap<int, QString> QmuParserBase::GetTokens() const inline QMap<int, QString> QmuParserBase::GetTokens() const
{ {
return m_Tokens; return m_Tokens;
} }
//---------------------------------------------------------------------------------------------------------------------
inline QMap<int, QString> QmuParserBase::GetNumbers() const inline QMap<int, QString> QmuParserBase::GetNumbers() const
{ {
return m_Numbers; return m_Numbers;

View File

@ -22,11 +22,10 @@
#include "qmuparserbytecode.h" #include "qmuparserbytecode.h"
#include <cassert> #include <QStack>
#include <string>
#include <stack>
#include <iostream>
#include <QString> #include <QString>
#include <QtMath>
#include <QDebug>
#include "qmuparserdef.h" #include "qmuparserdef.h"
#include "qmuparsererror.h" #include "qmuparsererror.h"

View File

@ -26,6 +26,7 @@
#include "qmuparser_global.h" #include "qmuparser_global.h"
#include <sstream> #include <sstream>
#include <QException> #include <QException>
#include <QVector>
#include "qmuparserdef.h" #include "qmuparserdef.h"

View File

@ -22,8 +22,8 @@
#include "qmuparsertokenreader.h" #include "qmuparsertokenreader.h"
#include "qmuparserbase.h" #include "qmuparserbase.h"
#include <QStringList> #include <QStringList>
#include <QDebug>
/** /**
* @file * @file

View File

@ -36,9 +36,6 @@
#if defined __cplusplus #if defined __cplusplus
/* Add C++ includes here */ /* Add C++ includes here */
#ifdef Q_CC_MSVC
#define _USE_MATH_DEFINES
#endif
#ifdef QT_CORE_LIB #ifdef QT_CORE_LIB
#include <QtCore> #include <QtCore>