gtkmm statusicon quits after creation
问题 I have to create a simple application that displays an icon in the systray and a menu from which you can do some operations. the problem is that statusicon is closed immediately after creation. What's missing? I put the sleep to make sure it was created. for 3 seconds something appears in systray, even if it is not the icon that I set. Init.cc #include <gtkmm/main.h> #include "Tray.h" int main(int argc, char *argv[]) { Gtk::Main kit(argc, argv); printf("Statuicon starting\n"); Tray tray;