Need help on: Linux Gnome2 Glade Cairo callback problem

Hi,
I have a Glade project main app window with a toolbar and 4
'drawingarea’s, into which I draw some test images using Cairo.
After anywhere between 50 and 100 drawingarea updates I get the
following message when clicking on a toolbar button.

cairo_test_2.rb:147: warning: GRClosure invoking callback: already
destroyed

Before the 50-100 drawingarea updates, the callback works fine.
Could anyone possibly tell me, or offer an opinion as to why the
callback is getting destroyed?
All I am doing is updating the drawing areas and clicking on a toolbar
button.

I use Ubuntu Linux, Gnome2, Glade2 and Cairo of course.

Thanks, Mike

Hi,

In [email protected]
“need help on: Linux Gnome2 Glade Cairo callback problem” on Thu, 12
Oct 2006 10:10:05 +0900,
Mike D. [email protected] wrote:

I have a Glade project main app window with a toolbar and 4
'drawingarea’s, into which I draw some test images using Cairo.
After anywhere between 50 and 100 drawingarea updates I get the
following message when clicking on a toolbar button.

cairo_test_2.rb:147: warning: GRClosure invoking callback: already destroyed

I fixed this bug in CVS.

The following patch may solve this bug.

— libglade2.rb 8 Jul 2006 16:45:15 -0000 1.13
+++ libglade2.rb 12 Oct 2006 13:50:17 -0000 1.14
@@ -40,6 +40,11 @@
end

 if signal_proc
  •  @sources ||= {}
    
  •  @sources[source.object_id] = source
    
  •  source.signal_connect("destroy") do |object|
    
  •    @sources.delete(object.object_id)
    
  •  end
     case signal_proc.arity
     when 0
       sig_conn_proc.call(signal) {signal_proc.call}
    

Thanks,

Kouhei S. wrote:

Thanks,

kou

Thanks Kou, your patch fixed the problem perfectly. Just out of
interest, where can I get libglade2.rb 1.14? I don’t understand the CVS
thing, where is it?.
Thanks again, Mike

Kouhei S. wrote:

thing, where is it?.
kou

Thank again Kou

Cheers, Mike

Hi,

2006/10/13, Mike D. [email protected]:

Thanks Kou, your patch fixed the problem perfectly.

It’s a good news. :slight_smile:

Just out of
interest, where can I get libglade2.rb 1.14? I don’t understand the CVS
thing, where is it?.

See Ruby-GNOME 2 download | SourceForge.net.

In this case, you will type the following command:
% cvs -z3
-d:pserver:[email protected]:/cvsroot/ruby-gnome2
co -P ruby-gnome2/libglade

Thanks,