diff --git a/ChangeLog b/ChangeLog index ee4e499a3..053d9b7e4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2004-05-07 Mike Kestner + + * sample/GnomeHelloWorld.cs : guard against null args.Event in the + icon_selected_cb, which occurs on button-presses for some reason. + Thanks to wmealing on irc for the bug report. + 2004-05-07 Mike Kestner * sample/*/Makefile.am : rebuild if the assemblies change diff --git a/sample/GnomeHelloWorld.cs b/sample/GnomeHelloWorld.cs index 96a8187a9..8230932b8 100644 --- a/sample/GnomeHelloWorld.cs +++ b/sample/GnomeHelloWorld.cs @@ -151,6 +151,10 @@ namespace GtkSamples { void icon_selected_cb (object obj, Gnome.IconSelectedArgs args) { int idx = args.Num; + + if (args.Event == null) + return; + EventButton ev = new EventButton (args.Event.Handle); if (ev.Type == EventType.TwoButtonPress && ev.Button == 1) {