Commit f0865b5
committed
fix: tooltip does not show the latest text
在这paintEvent中判断文本是否发生变化,如果变化了则调用DToolTip::setShowToolTip(this, false)重置状态,
确保Tooltip能显示最新的文本内容。为此在DLabelPrivate中增加了lastText成员变量用于记录上一次的文本。
Check if the text has changed in paintEvent. If it has changed, call DToolTip::setShowToolTip(this, false)
to reset the status, ensuring that the Tooltip displays the latest text content. To achieve this,
a lastText member variable was added to DLabelPrivate to record the previous text.
Log: fix tooltip does not show the latest text
Pms: BUG-3008371 parent 7446242 commit f0865b5
2 files changed
+7
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
207 | 207 | | |
208 | 208 | | |
209 | 209 | | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
210 | 216 | | |
211 | 217 | | |
212 | 218 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| 30 | + | |
30 | 31 | | |
31 | 32 | | |
32 | 33 | | |
| |||
0 commit comments