mirror of https://gitee.com/cxasm/notepad--.git
qt5/6: 处理在 Windows 中的 Qt6 转化处理
This commit is contained in:
parent
351a95b288
commit
cc4ec3da28
|
@ -53,9 +53,11 @@
|
|||
#include <QDateTime>
|
||||
#include <QShortcut>
|
||||
#ifdef Q_OS_WIN
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0))
|
||||
#include <QXmlQuery>
|
||||
#include <QXmlFormatter>
|
||||
#endif
|
||||
#endif
|
||||
#include <QBuffer>
|
||||
#include <QXmlStreamReader>
|
||||
#include <QJsonObject>
|
||||
|
@ -7593,7 +7595,11 @@ bool CCNotePad::nativeOpenfile(QString openFilePath)
|
|||
this->activateWindow();
|
||||
return true;
|
||||
}
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0))
|
||||
bool CCNotePad::nativeEvent(const QByteArray & eventType, void * message, long * result)
|
||||
#else
|
||||
bool CCNotePad::nativeEvent(const QByteArray & eventType, void * message, qintptr * result)
|
||||
#endif
|
||||
{
|
||||
MSG *param = static_cast<MSG *>(message);
|
||||
|
||||
|
|
|
@ -196,7 +196,11 @@ protected:
|
|||
void dropEvent(QDropEvent* e) override;
|
||||
bool eventFilter(QObject *watched, QEvent *event)override;
|
||||
#ifdef Q_OS_WIN
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0))
|
||||
bool nativeEvent(const QByteArray &eventType, void *message, long *result) override;
|
||||
#else
|
||||
bool nativeEvent(const QByteArray &eventType, void *message, qintptr *result);
|
||||
#endif
|
||||
bool nativeOpenfile(QString openFilePath);
|
||||
#endif
|
||||
#ifdef uos
|
||||
|
|
|
@ -103,7 +103,11 @@ bool UserLexDef::writeUserSettings(QString langTagName)
|
|||
qs.setValue("mz", langTagName);
|
||||
qs.setValue("mother", m_motherLang);
|
||||
qs.setValue("ext", m_extTypes);
|
||||
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0))
|
||||
qs.setValue("keyword", m_keyword.data());
|
||||
#else
|
||||
qs.setValue("keyword", QString(m_keyword.data()));
|
||||
#endif
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue