After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 731857 - Tray Icon does not shows in gnome-shell
Tray Icon does not shows in gnome-shell
Status: RESOLVED DUPLICATE of bug 721596
Product: gnome-shell
Classification: Core
Component: message-tray
3.1.x
Other Linux
: Normal normal
: ---
Assigned To: gnome-shell-maint
gnome-shell-maint
Depends on:
Blocks:
 
 
Reported: 2014-06-18 14:39 UTC by alexkutsan
Modified: 2015-01-24 00:39 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Screenshots (530.94 KB, application/zip)
2014-06-18 14:39 UTC, alexkutsan
Details

Description alexkutsan 2014-06-18 14:39:52 UTC
Created attachment 278686 [details]
Screenshots

If between gtk_status_icon_set_from_file() and gtk_main() was too much time. Tray icon appears with no image. 

Steps to reproduce:
1) Use this code

#include <gtk/gtk.h>
#include <unistd.h>
#define SLEEP_TIME 1

int main(int argc, char **argv)
{
	gtk_init(&argc, &argv);
	GtkStatusIcon *tray_icon;
	tray_icon = gtk_status_icon_new();
	gtk_status_icon_set_from_file(tray_icon, argv[1]);
	gtk_status_icon_set_visible(tray_icon, TRUE);
	printf("Wait\n");
	sleep(SLEEP_TIME);
	printf("Do!\n");
	gtk_main();
	return 0;
}

2) Compile with 
        $ g++ ./main.cpp `pkg-config --cflags --libs gtk+-2.0` -o gtk2_sleep1
3) run: 
        $ ./gtk2_sleep1 <PATH_TO_ICON>; 

Expected result: icon shows in tray with image .
Actual result: Icon shoes in tray with no image. (see gtk2_sleep1.png in attachments)

If setup SLEEP_TIME to 0, icon shows successfully. (see gtk2_sleep0.png in attachments)

If compile with:
g++ ./main.cpp `pkg-config --cflags --libs gtk+-3.0` -o gtk3_sleep1

Icon shows with small image. (see gtk3_sleep1.png and gtk3_sleep0.png in attachments)
Comment 1 Andrej Antonov 2014-06-18 15:06:45 UTC
I have this issue too.

my software versions:

OS: Arch Linux

gnome-shell version 3.12.2-1
gtk2 version 2.24.23-1
gtk3 version 3.12.2-1
Comment 2 Andrej Antonov 2014-06-18 21:23:08 UTC
have the ability to change ticket's "Product:gtkmm" to "Product:gnome-shell"?
Comment 3 André Klapper 2015-01-24 00:39:41 UTC
Marking as duplicate of bug 721596 to have discussion about this problem in one place.

*** This bug has been marked as a duplicate of bug 721596 ***