hc
2023-02-13 e440ec23c5a540cdd3f7464e8779219be6fd3d95
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
From 1e3b0a1d2cdba88b2db432309bb91e656c22b62a Mon Sep 17 00:00:00 2001
From: Jeffy Chen <jeffy.chen@rock-chips.com>
Date: Wed, 25 Nov 2020 15:43:25 +0800
Subject: [PATCH 27/31] qlayoutitem: Force disable size cache
 
Somehow the size cache might result in empty size hint randomly.
 
Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com>
---
 src/widgets/kernel/qlayoutitem.cpp | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
 
diff --git a/src/widgets/kernel/qlayoutitem.cpp b/src/widgets/kernel/qlayoutitem.cpp
index af575077..74d78261 100644
--- a/src/widgets/kernel/qlayoutitem.cpp
+++ b/src/widgets/kernel/qlayoutitem.cpp
@@ -730,7 +730,8 @@ QSizePolicy::ControlTypes QWidgetItem::controlTypes() const
 
 inline bool QWidgetItemV2::useSizeCache() const
 {
-    return wid->d_func()->widgetItem == this;
+    /* HACK: Force disable size cache */
+    return false;//wid->d_func()->widgetItem == this;
 }
 
 void QWidgetItemV2::updateCacheIfNecessary() const
-- 
2.20.1