Re-creating Gtk Menu in event handler with Vala fails

Bug #1809850 reported by sdaau
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
libappindicator (Ubuntu)
New
Undecided
Unassigned

Bug Description

There is a plugin that I'd like to get running, which fails because of this issue; I've discussed it, and manage to isolate it, in these two posts:

* https://askubuntu.com/questions/1089516/gnome3-appindicator-vala-app-cannot-show-submenu-it-auto-closes-immediately/
* https://stackoverflow.com/questions/53805975/re-creating-gtk-menu-in-event-handler-with-vala

The `test.vala` file from the second post is attached, it can be built with:

valac -X -D'GETTEXT_PACKAGE="my-indicator"' -D NEWMETHOD --pkg=gtk+-3.0 --pkg appindicator3-0.1 test.vala

... the `-D NEWMETHOD` simply replaces the deprecated Gtk.ImageMenuItem with Gtk.MenuItem, so as to get rid of deprecation warnings, but the behavior is exactly the same.

And the problem is: if a submenu creation code runs in an activate.connect handler, the created menu items never show. The animated .gif showing the issue (also in the above posts) is here:

https://i.stack.imgur.com/wA6kT.gif

Since this (creating submenu items in activate.connect handler) apparently worked at a point in the past, I'd consider the behavior I currently experience a bug.

Revision history for this message
sdaau (sd-imi) wrote :
sdaau (sd-imi)
summary: - Re-creating Gtk Menu in event handler with Vala?
+ Re-creating Gtk Menu in event handler with Vala fails
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.