Center system menu relative to its panel button

gh-2272
This commit is contained in:
Charles Gagnon
2025-03-10 16:15:10 -04:00
parent 8caef79463
commit 4e1f85f19b

View File

@@ -1104,6 +1104,12 @@ export const Panel = GObject.registerClass(
this._setVertical(this.panel, this.checkIfVertical()) this._setVertical(this.panel, this.checkIfVertical())
// center the system menu popup relative to its panel button
if (this.statusArea.quickSettings?.menu) {
this.statusArea.quickSettings.menu._arrowSide = this.geom.position
this.statusArea.quickSettings.menu._arrowAlignment = 0.5
}
// styles for theming // styles for theming
Object.keys(St.Side).forEach((p) => { Object.keys(St.Side).forEach((p) => {
let cssName = 'dashtopanel' + p.charAt(0) + p.slice(1).toLowerCase() let cssName = 'dashtopanel' + p.charAt(0) + p.slice(1).toLowerCase()