From 52a662ed17db6c3a3ff2050d61bc2e06ea21b056 Mon Sep 17 00:00:00 2001
From: Sine Striker <trueful@163.com>
Date: 周日, 17 12月 2023 01:07:13 +0800
Subject: [PATCH] Add Mac system button area interfaces

---
 src/core/contexts/abstractwindowcontext.cpp |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

diff --git a/src/core/contexts/abstractwindowcontext.cpp b/src/core/contexts/abstractwindowcontext.cpp
index 96f2935..7c40c89 100644
--- a/src/core/contexts/abstractwindowcontext.cpp
+++ b/src/core/contexts/abstractwindowcontext.cpp
@@ -76,6 +76,13 @@
         return true;
     }
 
+#ifdef Q_OS_MAC
+    void AbstractWindowContext::setSystemButtonArea(const QRect &rect) {
+        m_systemButtonArea = rect;
+        virtual_hook(SystemButtonAreaChangedHook, nullptr);
+    }
+#endif
+
     bool AbstractWindowContext::isInSystemButtons(const QPoint &pos,
                                                   WindowAgentBase::SystemButton *button) const {
         *button = WindowAgentBase::Unknown;

--
Gitblit v1.9.1