fix: update tooltip window property bindings and hover behavior#1549
Merged
Conversation
Reviewer's guide (collapsed on small PRs)Reviewer's GuideThis PR adjusts tooltip sizing bindings to use requested dimensions, ensures quick panel tooltips close when the panel opens, and simplifies hover handling to make hover behavior consistent regardless of panel state. Sequence diagram for updated quick panel tooltip behaviorsequenceDiagram
actor User
participant PanelTrayItem
participant HoverHandler
participant PanelToolTip
participant ToolTipWindow
participant QuickPanel
User->>HoverHandler: pointer enters icon area
HoverHandler->>PanelTrayItem: onHoveredChanged(hovered = true)
PanelTrayItem->>PanelToolTip: open tooltip when !isOpened
PanelToolTip->>PanelToolTip: calculate width and height
PanelToolTip->>ToolTipWindow: set requestedWidth
PanelToolTip->>ToolTipWindow: set requestedHeight
ToolTipWindow-->>User: display tooltip
User->>QuickPanel: open quick panel
QuickPanel->>PanelTrayItem: set isOpened = true
PanelTrayItem->>PanelTrayItem: onIsOpenedChanged
PanelTrayItem->>PanelToolTip: toolTip.close()
PanelToolTip->>ToolTipWindow: close window
ToolTipWindow-->>User: hide tooltip
User->>HoverHandler: pointer moves while panel open
HoverHandler->>PanelTrayItem: onHoveredChanged(hovered changes)
PanelTrayItem->>PanelToolTip: do not reopen tooltip when isOpened = true
Class diagram for updated PanelToolTip and PanelTrayItemclassDiagram
class PanelTrayItem {
bool isOpened
bool contentHovered
PanelToolTip toolTip
void onIsOpenedChanged()
void onHoveredChanged(bool hovered)
}
class PanelToolTip {
ToolTipWindow toolTipWindow
double width
double height
double leftPadding
double rightPadding
bool readyBinding
void bindRequestedWidth()
void bindRequestedHeight()
}
class ToolTipWindow {
double requestedWidth
double requestedHeight
void close()
}
class HoverHandler {
void onHoveredChanged(bool hovered)
}
PanelTrayItem --> PanelToolTip : contains
PanelToolTip --> ToolTipWindow : configures
PanelTrayItem --> HoverHandler : uses
HoverHandler --> PanelTrayItem : notifies hover state
PanelToolTip : bindRequestedWidth() uses toolTipWindow.requestedWidth
PanelToolTip : bindRequestedHeight() uses toolTipWindow.requestedHeight
PanelTrayItem : onIsOpenedChanged() calls toolTip.close()
PanelTrayItem : onHoveredChanged() shows tooltip only when !isOpened
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
yixinshark
previously approved these changes
Apr 9, 2026
1. Changed tooltip window property bindings from "width"/"height" to
"requestedWidth"/"requestedHeight" in PanelToolTip.qml
2. Added tooltip close functionality when quick panel is opened in
PanelTrayItem.qml
3. Removed hover handler enabled condition to ensure consistent hover
behavior
The changes update tooltip property bindings to use more appropriate
property names ("requestedWidth"/"requestedHeight") which better
reflect their purpose. Also fixes tooltip behavior by closing it when
the quick panel opens, preventing tooltips from remaining visible when
they shouldn't be. The hover handler condition removal ensures hover
detection works consistently regardless of panel state.
Log: Fixed tooltip behavior in quick panel - tooltips now properly close
when panel opens
Influence:
1. Test tooltip display when hovering over quick panel icon
2. Verify tooltip disappears when quick panel is opened
3. Check tooltip positioning and sizing with different content
4. Test hover behavior consistency when panel is open/closed
5. Verify no visual artifacts or overlapping elements
fix: 更新工具提示窗口属性绑定和悬停行为
1. 在 PanelToolTip.qml 中将工具提示窗口属性绑定从 "width"/"height" 改为
"requestedWidth"/"requestedHeight"
2. 在 PanelTrayItem.qml 中添加快速面板打开时关闭工具提示的功能
3. 移除悬停处理器的启用条件以确保一致的悬停行为
这些更改将工具提示属性绑定更新为使用更合适的属性名称
("requestedWidth"/"requestedHeight"),更好地反映其用途。同时修复了工具
提示行为,在快速面板打开时关闭工具提示,防止工具提示在不应该显示时仍然可
见。移除悬停处理器条件可确保悬停检测无论面板状态如何都能一致工作。
Log: 修复快速面板中的工具提示行为 - 面板打开时工具提示现在能正确关闭
Influence:
1. 测试悬停在快速面板图标上时工具提示的显示
2. 验证打开快速面板时工具提示是否消失
3. 检查不同内容下工具提示的定位和大小调整
4. 测试面板打开/关闭时的悬停行为一致性
5. 验证没有视觉伪影或元素重叠
PMS: BUG-296251
6194b42 to
68f5079
Compare
yixinshark
approved these changes
Apr 9, 2026
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: wjyrich, yixinshark The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Contributor
Author
|
/forcemerge |
|
This pr force merged! (status: blocked) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The changes update tooltip property bindings to use more appropriate property names ("requestedWidth"/"requestedHeight") which better reflect their purpose. Also fixes tooltip behavior by closing it when the quick panel opens, preventing tooltips from remaining visible when they shouldn't be. The hover handler condition removal ensures hover detection works consistently regardless of panel state.
Log: Fixed tooltip behavior in quick panel - tooltips now properly close when panel opens
Influence:
fix: 更新工具提示窗口属性绑定和悬停行为
这些更改将工具提示属性绑定更新为使用更合适的属性名称
("requestedWidth"/"requestedHeight"),更好地反映其用途。同时修复了工具 提示行为,在快速面板打开时关闭工具提示,防止工具提示在不应该显示时仍然可
见。移除悬停处理器条件可确保悬停检测无论面板状态如何都能一致工作。
Log: 修复快速面板中的工具提示行为 - 面板打开时工具提示现在能正确关闭
Influence:
PMS: BUG-296251
Summary by Sourcery
Align tooltip sizing and visibility behavior for quick panel items to ensure consistent hover interaction and correct closing when the panel opens.
Bug Fixes:
Enhancements: