Mark Leisher wrote:
Attached are two small programs, gtk.c and x11.c. Both are meant to demonstrate how to use a GdkAtom/Atom to determine if an instance of a program is already running (Linux/Unix).
I've finally tracked down the problem. When the call to gdk_selection_owner_get() is done, the proper selection XID is returned as being the owner of the selection, but there is no entry in the GtkDisplay's XID hashtable (xid_ht).
The value of the XIDs look suspiciously like temporary values, so the selection might have to be owned later, when a real XID exists. More experiments later.
This is true for versions gtk+ 2.2.4, 2.7.2 and 2.8.9. Anyone interested in this obscure problem can get the two example files at: http://crl.nmsu.edu/~mleisher/gtk.c http://crl.nmsu.edu/~mleisher/x11.c -- --------------------------------------------------------------------------- Mark Leisher Computing Research Lab A sneer is the weapon of the weak. New Mexico State University -- James Russell Lowell (1819-1891) Box 30001, MSC 3CRL Las Cruces, NM 88003 _______________________________________________ gtk-list@xxxxxxxxx http://mail.gnome.org/mailman/listinfo/gtk-list