CMakeLists.txt | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
src/quick/quickwindowagent_win.cpp | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
src/widgets/widgetwindowagent_win.cpp | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
CMakeLists.txt
@@ -14,7 +14,7 @@ option(QWINDOWKIT_ENABLE_QT_WINDOW_CONTEXT "Enable Qt Window Context anyway" OFF) option(QWINDOWKIT_ENABLE_STYLE_AGENT "Enable building style agent" ON) option(QWINDOWKIT_ENABLE_WINDOWS_SYSTEM_BORDER "Disable system border on Windows" ON) option(QWINDOWKIT_ENABLE_WINDOWS_SYSTEM_BORDER "Enable system border on Windows" ON) # ---------------------------------- # CMake Settings src/quick/quickwindowagent_win.cpp
@@ -3,10 +3,13 @@ #include <QtQuick/QQuickPaintedItem> #include <QtQuick/private/qquickitem_p.h> #include <QWKCore/qwindowkit_windows.h> #include <QWKCore/qwkconfig.h> #include <QWKCore/private/nativeeventfilter_p.h> namespace QWK { #if QWINDOWKIT_CONFIG(ENABLE_WINDOWS_SYSTEM_BORDER) class BorderItem : public QQuickPaintedItem, public NativeEventFilter { public: explicit BorderItem(QQuickItem *parent, AbstractWindowContext *context); @@ -109,13 +112,16 @@ void BorderItem::_q_windowActivityChanged() { update(); } #endif void QuickWindowAgentPrivate::setupWindows10BorderWorkaround() { #if QWINDOWKIT_CONFIG(ENABLE_WINDOWS_SYSTEM_BORDER) // Install painting hook auto ctx = context.get(); if (ctx->property("needBorderPainter").toBool()) { std::ignore = new BorderItem(hostWindow->contentItem(), ctx); } #endif } } src/widgets/widgetwindowagent_win.cpp
@@ -1,11 +1,9 @@ #include "widgetwindowagent_p.h" #include <QWKCore/qwkconfig.h> #include <QWKCore/qwkglobal.h> #include <QtGui/QPainter> #include <QWKCore/qwindowkit_windows.h> #include <QWKCore/qwkconfig.h> #include <QWKCore/private/nativeeventfilter_p.h> namespace QWK {