views:

188

answers:

3

In Gnome, whenever an application is started, the mouse cursor changes from normal to an activity indicator (a spinning wheel type thing on Ubuntu). Is there any way to inform Gnome (through some system call) when the application has finished launching so that the mouse cursor returns to normal without waiting for the usual timeout of 30 seconds to occur.

I have a program in Pythong using GTK+ that is showing the icon even after launching, so what system call do I make?

A: 

This normally happens automatically when calling the gtk.main() function

Mez
+2  A: 

Normally it happens automatically when you open the application's window.

It may be that the application's launcher just calls an already running instance, in that case it won't be automatically detected. The call you need then is this:

import gtk
gtk.gdk.notify_startup_complete()
kaizer.se
A: 

Your application can opt out of startup notification by adding

StartupNotify=false

to your application's .desktop file.

Of course, it is friendlier to leave it enabled and participate in startup notification.

ephemient