Ok I am editting google sketchups base and I have built a ruby plugin
however I want an event to happen on close.
[...]
Then you might have better luck asking on the Sketchup development list
or the general Ruby list. This is the Rails list, and you don't appear
to be using Rails here (right?).