On Wed, Aug 4, 2010 at 4:46 PM, Matthew Pirocchi <[email protected]> wrote: > public class GmailAppIndicator { > public GmailAppIndicator () > { > ApplicationIndicator indicator = new ApplicationIndicator ("gmail-notifier", > "gmail", > > Category.ApplicationStatus); > Gtk.Menu menu = new Gtk.Menu (); > Gtk.MenuItem testMenuItem = new Gtk.ImageMenuItem (Gtk.Stock.About, null); > menu.Add (testMenuItem); > menu.ShowAll (); > indicator.Menu = menu; > indicator.Status = Status.Active; > } > } > ... > public static void Main (string[] args) > { > Gtk.Application.Init (); > GmailAppIndicator indicator = new GmailAppIndicator (); > Gtk.Application.Run (); > } > Any idea why this is happening?
The ApplicationIndicator object will be garbage-collected any time after the GmailAppIndicator ctor ends. You should keep a reference, e.g. on a field in GmailAppIndicator. -- Michael Hutchinson http://mjhutchinson.com _______________________________________________ Gtk-sharp-list maillist - [email protected] http://lists.ximian.com/mailman/listinfo/gtk-sharp-list
