4 Star 0 Fork 4

src-openEuler/kiran-qt5-integration

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
0009-fix-qt5.9.7-fits-the-Qt5.9.7-interface.patch 1.65 KB
一键复制 编辑 原始数据 按行查看 历史
From e58669401e8e2b2a9e5c5654a2bd58444756ad71 Mon Sep 17 00:00:00 2001
From: liuxinhao <liuxinhao@kylinsec.com.cn>
Date: Tue, 5 Sep 2023 14:30:25 +0800
Subject: [PATCH] fix(qt5.9.7): fits the Qt5.9.7 interface
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
- 适配Qt5.9.7接口,修复编译报错
---
style/src/style.cpp | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/style/src/style.cpp b/style/src/style.cpp
index abe5517..2161c65 100644
--- a/style/src/style.cpp
+++ b/style/src/style.cpp
@@ -93,12 +93,15 @@ int Style::styleHint(QStyle::StyleHint hint, const QStyleOption *option, const Q
// 弹出菜单是否支持用户在跨越菜单的其他项时将鼠标光标移动到子菜单
case SH_Menu_SloppySubMenus:
return true;
+#if (QT_VERSION < QT_VERSION_CHECK(5, 10, 0))
// 该值目前亦废弃,改用SH_Widget_Animation_Duration
case SH_Widget_Animate:
return true;
+#else
// 动画持续时间ms,0代表禁用
case SH_Widget_Animation_Duration:
return 100;
+#endif
// 确定样式是在菜单中显示节,还是将其视为普通分隔符。节是带有文本和图标提示的分隔符
case SH_Menu_SupportsSections:
return true;
@@ -327,7 +330,7 @@ void Style::drawPrimitive(QStyle::PrimitiveElement element, const QStyleOption *
// clang-format off
switch (element)
- {
+ {
case PE_Frame: func = &drawPEFrame; break;
case PE_FrameFocusRect: func = &drawPEFrameFocusRect; break;
case PE_FrameGroupBox: func = &drawPEFrameGroupBox; break;
--
2.33.0
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/src-openeuler/kiran-qt5-integration.git
git@gitee.com:src-openeuler/kiran-qt5-integration.git
src-openeuler
kiran-qt5-integration
kiran-qt5-integration
master

搜索帮助