[GH-ISSUE #1395] Menu entries only appear when opening via mouse #4636

Closed
opened 2026-05-23 00:54:48 +01:00 by JakeStanger · 3 comments
Owner

Originally created by @dae-vinity on GitHub (Feb 23, 2026).
Original GitHub issue: https://github.com/JakeStanger/ironbar/issues/1395

Describe the bug
i've configured labwc to open the menu module popup when my start key is pressed
this works most of the time, but if you're opening the menu for the first time after a reload or reboot, no entries will load unless you click the button with your pointer.
this is a very very small bug so you don't need to worry about it if you don't want to but it does happen

To reproduce
Steps to reproduce the behavior:

  1. ironbar reload
  2. ironbar bar {bar-name} toggle-popup menu

Expected behavior
menu entries to load upon any interaction

System information:

  • Distro: Arch Linux x64
  • Compositor: labwc
  • Ironbar version: 0.18.0

Screenshots

Image

after clicking:
Image

Originally created by @dae-vinity on GitHub (Feb 23, 2026). Original GitHub issue: https://github.com/JakeStanger/ironbar/issues/1395 **Describe the bug** i've configured labwc to open the menu module popup when my start key is pressed this works most of the time, but if you're opening the menu for the first time after a reload or reboot, no entries will load unless you click the button with your pointer. this is a very very small bug so you don't need to worry about it if you don't want to but it does happen **To reproduce** Steps to reproduce the behavior: 1. `ironbar reload` 2. `ironbar bar {bar-name} toggle-popup menu` **Expected behavior** menu entries to load upon any interaction **System information:** - Distro: Arch Linux x64 - Compositor: labwc - Ironbar version: 0.18.0 **Screenshots** <!-- If applicable, add screenshots to help explain your problem. --> <img width="644" height="189" alt="Image" src="https://github.com/user-attachments/assets/aaa140f0-19a6-4461-9a94-9c0b75559599" /> after clicking: <img width="132" height="386" alt="Image" src="https://github.com/user-attachments/assets/38f928ec-8899-47b3-b9a6-61d224f67d77" />
Author
Owner

@JakeStanger commented on GitHub (Feb 23, 2026):

Interesting.

The problem is that the menu module needs to perform a lot of I/O to parse all the desktop files, so it offsets it until the first click to avoid hanging the whole bar on startup. That's why the first click takes longer, and explains what you're seeing.

github.com/JakeStanger/ironbar@172f385fb0/src/modules/menu/mod.rs (L140-L146)

I think it might be as simple as moving the call from the click handler, to a handler that listens to the popup's popover widget opening. I don't think that should have any change in behaviour.

<!-- gh-comment-id:3947790861 --> @JakeStanger commented on GitHub (Feb 23, 2026): Interesting. The problem is that the menu module needs to perform a lot of I/O to parse all the desktop files, so it offsets it until the first click to avoid hanging the whole bar on startup. That's why the first click takes longer, and explains what you're seeing. https://github.com/JakeStanger/ironbar/blob/172f385fb0108040d3cd17162a9ea1b20285a603/src/modules/menu/mod.rs#L140-L146 I think it might be as simple as moving the call from the click handler, to a handler that listens to the popup's popover widget opening. I don't think that should have any change in behaviour.
Author
Owner

@JakeStanger commented on GitHub (Feb 24, 2026):

I'm going to reopen this as I've just realised my fix has now caused the menu to open whenever you open a popup for the first time for any module.

<!-- gh-comment-id:3955309204 --> @JakeStanger commented on GitHub (Feb 24, 2026): I'm going to reopen this as I've just realised my fix has now caused the menu to open whenever you open a popup for the first time for any module.
Author
Owner

@JakeStanger commented on GitHub (Feb 28, 2026):

Properly fixed by github.com/JakeStanger/ironbar@e60eb4c050

<!-- gh-comment-id:3976906630 --> @JakeStanger commented on GitHub (Feb 28, 2026): Properly fixed by https://github.com/JakeStanger/ironbar/commit/e60eb4c05019eb63c6b083e4a27ddf4c9e21c82e
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
JakeStanger/ironbar#4636
No description provided.