Give the weather panel its host widget's identity in the bar
The bar identifies a panel by the widget mounted in its slot, but the nested panel handed the popout coordinator itself. The open-panel mark never lit under the weather pill, and Tab could not leave the panel. Closing for a popout switch also cleared the shared hover-reveal flag the incoming panel had just set. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5
parent
6d4fa7acaf
commit
c2610c3788
@@ -12,6 +12,7 @@ BarWidget {
|
||||
if ("bar" in target) target.bar = root.bar
|
||||
if ("settings" in target) target.settings = root.settings
|
||||
if ("anchorItem" in target) target.anchorItem = button
|
||||
if ("hostWidget" in target) target.hostWidget = root
|
||||
}
|
||||
|
||||
function refresh() {
|
||||
@@ -36,6 +37,15 @@ BarWidget {
|
||||
if (panelLoader.item && panelLoader.item.close) panelLoader.item.close()
|
||||
}
|
||||
|
||||
// Forwarded so this widget can stand in for the panel as the bar's popout
|
||||
// identity: Bar.requestPopout prefers closeForPopoutSwitch over close, and
|
||||
// KeyboardPanel reads popoutSwitchClosing back off its owner.
|
||||
readonly property bool popoutSwitchClosing: panelLoader.item ? panelLoader.item.popoutSwitchClosing === true : false
|
||||
|
||||
function closeForPopoutSwitch() {
|
||||
if (panelLoader.item) panelLoader.item.closeForPopoutSwitch()
|
||||
}
|
||||
|
||||
visible: panelLoader.item && panelLoader.item.label !== ""
|
||||
implicitWidth: button.implicitWidth
|
||||
implicitHeight: button.implicitHeight
|
||||
|
||||
Reference in New Issue
Block a user