mirror of
https://github.com/QtExcel/QXlsx.git
synced 2025-01-16 04:42:53 +08:00
update webserver example for qt6
This commit is contained in:
parent
ee99dd959c
commit
e67147ea36
@ -3,10 +3,6 @@
|
||||
TARGET = WebServer
|
||||
TEMPLATE = app
|
||||
|
||||
equals( QT_MAJOR_VERSION, 6 ) {
|
||||
QT += core5compat
|
||||
}
|
||||
|
||||
QT += core
|
||||
QT += network
|
||||
QT -= gui
|
||||
|
@ -5,10 +5,6 @@
|
||||
#include <QVariant>
|
||||
#include <QHash>
|
||||
|
||||
#if QT_VERSION_MAJOR >= 6 // Qt6 or higher version
|
||||
#include <QtCore5Compat>
|
||||
#endif
|
||||
|
||||
#include "request.hpp"
|
||||
#include "response.hpp"
|
||||
|
||||
|
@ -7,10 +7,6 @@
|
||||
#include <QVector>
|
||||
#include <QList>
|
||||
|
||||
#if QT_VERSION_MAJOR >= 6 // Qt6 or higher version
|
||||
#include <QtCore5Compat>
|
||||
#endif
|
||||
|
||||
#include "recurse.hpp"
|
||||
|
||||
#include "xlsxdocument.h"
|
||||
|
@ -18,7 +18,8 @@
|
||||
#include <QVector>
|
||||
|
||||
#if QT_VERSION_MAJOR >= 6 // Qt6 or higher version
|
||||
#include <QtCore5Compat>
|
||||
#include <QRegularExpression>
|
||||
#include <QRegularExpressionMatch>
|
||||
#endif
|
||||
|
||||
#include <functional>
|
||||
@ -439,10 +440,19 @@ namespace Recurse
|
||||
{
|
||||
QProcessEnvironment env = QProcessEnvironment::systemEnvironment();
|
||||
|
||||
#if QT_VERSION_MAJOR >= 6 // Qt6 or higher version
|
||||
QRegularExpression debug_strings("(recurse|development)");
|
||||
|
||||
QRegularExpressionMatch rem = debug_strings.match(env.value("DEBUG"));
|
||||
if ( rem.hasMatch() )
|
||||
m_debug = true;
|
||||
#else
|
||||
QRegExp debug_strings("(recurse|development)");
|
||||
|
||||
if (debug_strings.indexIn(env.value("DEBUG")) != -1)
|
||||
m_debug = true;
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
inline Application::Application(int &argc, char **argv, QObject *parent)
|
||||
|
@ -8,7 +8,7 @@
|
||||
#include <QUrlQuery>
|
||||
|
||||
#if QT_VERSION_MAJOR >= 6 // Qt6 or higher version
|
||||
#include <QtCore5Compat>
|
||||
#include <QRegularExpression>
|
||||
#endif
|
||||
|
||||
class Request
|
||||
|
@ -5,10 +5,6 @@
|
||||
#include <QHash>
|
||||
#include <QJsonDocument>
|
||||
|
||||
#if QT_VERSION_MAJOR >= 6 // Qt6 or higher version
|
||||
#include <QtCore5Compat>
|
||||
#endif
|
||||
|
||||
#include <functional>
|
||||
|
||||
class Response
|
||||
|
Loading…
x
Reference in New Issue
Block a user