search for: mark_wxmenubar

Displaying 2 results from an estimated 2 matches for "mark_wxmenubar".

2007 May 22
0
[1029] trunk/wxruby2/swig/classes/MenuBar.i: Add special GC protection for Wx::Menu to prevent premature destruction
...ine. This is because Wx::Menu is +// not a subclass of Window so isn''t automatically protected in the mark +// phase by Wx::App. However, the ruby object still must not be +// destroyed while the Menu is still accessible on screen, because it +// may be required to handle events. +%{ +void mark_wxMenuBar(void *ptr) +{ + VALUE rb_win = SWIG_RubyInstanceFor(ptr); + if ( rb_iv_get(rb_win, "@__wx_destroyed__") == Qtrue ) +&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp return; </ins><span class="cx"> </span><ins>+ wxMenuBar* men...
2007 Jul 05
0
[1109] trunk/wxruby2/swig: Move marking of MenuBar from direct %markfunc to via mark_wxFrame, so
...ine. This is because Wx::Menu is -// not a subclass of Window so isn''t automatically protected in the mark -// phase by Wx::App. However, the ruby object still must not be -// destroyed while the Menu is still accessible on screen, because it -// may be required to handle events. -%{ -void mark_wxMenuBar(void *ptr) -{ - VALUE rb_win = SWIG_RubyInstanceFor(ptr); - if ( rb_iv_get(rb_win, "@__wx_destroyed__") == Qtrue ) -&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp return; - - wxMenuBar* menu_bar = (wxMenuBar*)ptr; - // Mark each menu in the menubar in turn...