Folo icon indicating copy to clipboard operation
Folo copied to clipboard

Tray menu unresponsive

Open Clackz opened this issue 7 months ago • 3 comments

Platform

Desktop - Linux

Describe the bug

我是manjaro,安装了folo后在设置了设置了最小化到托盘,然后点X按钮,任务栏能正常出现folo图标,托盘菜单也能正常弹出,但菜单是英文,并且点击open folo,quit folo等按钮也无任何反应,只能通过命令再打开,查看后台是正常运行的。

抓的部分日志:

[70737:0422/152528.358357:ERROR:dbus/exported_object.cc:104] org.kde.StatusNotifierItem.Activate is already exported
[70737:0422/152528.358387:ERROR:dbus/exported_object.cc:104] org.kde.StatusNotifierItem.ContextMenu is already exported
[70737:0422/152528.358396:ERROR:dbus/exported_object.cc:104] org.kde.StatusNotifierItem.Scroll is already exported
[70737:0422/152528.358404:ERROR:dbus/exported_object.cc:104] org.kde.StatusNotifierItem.SecondaryActivate is already exported
[70737:0422/152528.358412:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.AboutToShow is already exported
[70737:0422/152528.358419:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.AboutToShowGroup is already exported
[70737:0422/152528.358428:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.Event is already exported
[70737:0422/152528.358436:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.EventGroup is already exported
[70737:0422/152528.358444:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.GetGroupProperties is already exported
[70737:0422/152528.358453:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.GetLayout is already exported
[70737:0422/152528.358462:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.GetProperty is already exported
[70737:0422/152528.358470:ERROR:dbus/exported_object.cc:104] org.freedesktop.DBus.Properties.GetAll is already exported
[70737:0422/152528.358479:ERROR:dbus/exported_object.cc:104] org.freedesktop.DBus.Properties.Get is already exported
[70737:0422/152528.358485:ERROR:dbus/exported_object.cc:104] org.freedesktop.DBus.Properties.Set is already exported
[70737:0422/152528.358730:ERROR:dbus/exported_object.cc:104] org.freedesktop.DBus.Properties.GetAll is already exported
[70737:0422/152528.358737:ERROR:dbus/exported_object.cc:104] org.freedesktop.DBus.Properties.Get is already exported
[70737:0422/152528.358745:ERROR:dbus/exported_object.cc:104] org.freedesktop.DBus.Properties.Set is already exported
[70737:0422/152528.408319:ERROR:content/browser/browser_main_loop.cc:286] Gtk: gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed

Entry ID

No response

Relevant Information

No response

Reproduction Video

No response

Environment

No response

Validations

  • [x] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
  • [x] Check that this is a concrete bug. For Q&A, please open a GitHub Discussion instead.
  • [x] This issue is valid

Contributions

  • [ ] I am willing to submit a PR to fix this issue
  • [ ] I am willing to submit a PR with failing tests (actually just go ahead and do it, thanks!)

Clackz avatar Apr 22 '26 07:04 Clackz

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Platform

Desktop-Linux

Describe the bug

I am manjaro. After installing folo, I set the settings to minimize to the tray, and then clicked the X button. The folo icon can appear normally in the taskbar, and the tray menu can also pop up normally, but the menu is in English, and there is no response when clicking open folo, quit folo and other buttons. I can only open it again through commands. Check that the background is running normally.

Part of the log captured:

[70737:0422/152528.358357:ERROR:dbus/exported_object.cc:104] org.kde.StatusNotifierItem.Activate is already exported
[70737:0422/152528.358387:ERROR:dbus/exported_object.cc:104] org.kde.StatusNotifierItem.ContextMenu is already exported
[70737:0422/152528.358396:ERROR:dbus/exported_object.cc:104] org.kde.StatusNotifierItem.Scroll is already exported
[70737:0422/152528.358404:ERROR:dbus/exported_object.cc:104] org.kde.StatusNotifierItem.SecondaryActivate is already exported
[70737:0422/152528.358412:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.AboutToShow is already exported
[70737:0422/152528.358419:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.AboutToShowGroup is already exported
[70737:0422/152528.358428:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.Event is already exported
[70737:0422/152528.358436:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.EventGroup is already exported
[70737:0422/152528.358444:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.GetGroupProperties is already exported
[70737:0422/152528.358453:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.GetLayout is already exported
[70737:0422/152528.358462:ERROR:dbus/exported_object.cc:104] com.canonical.dbusmenu.GetProperty is already exported
[70737:0422/152528.358470:ERROR:dbus/exported_object.cc:104] org.freedesktop.DBus.Properties.GetAll is already exported
[70737:0422/152528.358479:ERROR:dbus/exported_object.cc:104] org.freedesktop.DBus.Properties.Get is already exported
[70737:0422/152528.358485:ERROR:dbus/exported_object.cc:104] org.freedesktop.DBus.Properties.Set is already exported
[70737:0422/152528.358730:ERROR:dbus/exported_object.cc:104] org.freedesktop.DBus.Properties.GetAll is already exported
[70737:0422/152528.358737:ERROR:dbus/exported_object.cc:104] org.freedesktop.DBus.Properties.Get is already exported
[70737:0422/152528.358745:ERROR:dbus/exported_object.cc:104] org.freedesktop.DBus.Properties.Set is already exported
[70737:0422/152528.408319:ERROR:content/browser/browser_main_loop.cc:286] Gtk: gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed

Entry ID

No response

Relevant Information

No response

Reproduction Video

No response

Environment

No response

Validations

  • [x] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
  • [x] Check that this is a concrete bug. For Q&A, please open a GitHub Discussion instead.
  • [x] This issue is valid

Contributions

  • [ ] I am willing to submit a PR to fix this issue
  • [ ] I am willing to submit a PR with failing tests (actually just go ahead and do it, thanks!)

github-actions[bot] avatar Apr 22 '26 07:04 github-actions[bot]

https://github.com/user-attachments/assets/b4c66c4e-15f3-4bee-b46b-6b3d19c0cfa5

Clackz avatar Apr 22 '26 07:04 Clackz

Fixed on dev in 4be035d37.

Root cause: the desktop main process recreated the native Tray when refreshing the tray menu after locale sync. On Linux/KDE this can leave duplicate StatusNotifierItem/DBus menu exports, which matches the reported already exported log and can make menu item activation stop working.

Change: reuse the existing Tray instance and refresh its context menu/tooltip instead. Added regression coverage to ensure repeated tray registration does not recreate the native tray.

Validation:

  • pnpm --dir apps/desktop/layer/main run test -- --run
  • pnpm --dir apps/desktop/layer/main exec tsc --noEmit --pretty false
  • pnpm exec eslint apps/desktop/layer/main/src/lib/tray.ts apps/desktop/layer/main/src/lib/tray.test.ts
  • pnpm exec prettier --check apps/desktop/layer/main/src/lib/tray.ts apps/desktop/layer/main/src/lib/tray.test.ts

Closing as fixed.

DIYgod avatar May 12 '26 08:05 DIYgod