[Gtk-sharp-list] Overriding OnDestroyEvent

Chris Seaton chris at chrisseaton.com
Fri Mar 9 08:26:10 EST 2007


I don't seem to be able to override OnDestroyEvent in my Window  
subclass.

         protected override bool OnDestroyEvent(Gdk.Event args)
         {
             Console.WriteLine("b");

             if (base.OnDestroyEvent(args))
                 return true;

             Console.WriteLine("c");

             return false;
         }

I explicitly call Destroy for the Window

	Console.WriteLine("a");
	mainWindow.Destroy();
	Console.WriteLine("b");

I see a and b printed on the screen, but not c or d.

What could be wrong?

Thanks

Chris Seaton


More information about the Gtk-sharp-list mailing list