[Gtk-sharp-list] GIO# System.InvalidCastException in VolumeMonitor.MountAdded event
Christian Hoff
christian_hoff at gmx.net
Sun Oct 11 10:07:52 EDT 2009
Chris Szikszoy wrote:
> Hi Christian,
>
> Thanks for the patch. I gave it a try but am getting a different
> exception now (with your test program). I see that the generated code (from MD's assembly
> browser now shows:
> get {
> return
> GLib.MountAdapter.GetObject(GLib.SignalArgs.get_Args()[1]);
> }
>
You have applied the patch against the current stable version (2.12) of
the code generator. If you apply it to the Gtk# trunk generator,
everything will work just fine.
> I was, however, able to finally get the Mount from the event by doing this:
> Mount m = GLib.MountAdapter.GetObject (a.Args [0] as GLib.Object);
> Console.WriteLine (m.Name);
>
Yeah, when I backport this patch, I will need to fix the array indices
as well. Great to see that you got it to work :-) . I'll commit when
we've got Mike's approval.
Christian
More information about the Gtk-sharp-list
mailing list