search for: markfunc

Displaying 20 results from an estimated 25 matches for "markfunc".

2007 Jul 21
0
[1137] trunk/wxruby2/swig/classes/TreeCtrl.i: Call correct shared function to check whether TreeCtrl is deleted in markfunc
...ck;padding:0 10px;} #patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;} #patch .lines, .info {color:#888;background:#fff;} --></style> <title>[1137] trunk/wxruby2/swig/classes/TreeCtrl.i: Call correct shared function to check whether TreeCtrl is deleted in markfunc</title> </head> <body> <div id="msg"> <dl> <dt>Revision</dt> <dd>1137</dd> <dt>Author</dt> <dd>brokentoy</dd> <dt>Date</dt> <dd>2007-07-21 12:47:32 -0400 (Sat, 21 Jul 2007)</dd> </dl&...
2007 Jul 05
0
[1109] trunk/wxruby2/swig: Move marking of MenuBar from direct %markfunc to via mark_wxFrame, so
...s {background:#dfd;text-decoration:none;display:block;padding:0 10px;} #patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;} #patch .lines, .info {color:#888;background:#fff;} --></style> <title>[1109] trunk/wxruby2/swig: Move marking of MenuBar from direct %markfunc to via mark_wxFrame, so</title> </head> <body> <div id="msg"> <dl> <dt>Revision</dt> <dd>1109</dd> <dt>Author</dt> <dd>brokentoy</dd> <dt>Date</dt> <dd>2007-07-05 14:45:10 -0400 (Thu, 05 Jul 2...
2007 May 28
0
[1033] trunk/wxruby2/swig: GC fixes for nested sizers; fix crashes in html.rb demo
...ss="cx"> %module(directors="1") wxBoxSizer </span><span class="cx"> GC_MANAGE_AS_OBJECT(wxBoxSizer); </span><span class="cx"> </span><ins>+ +// shared functions for GC marking +%include "../shared/sizers.i" +%markfunc wxBoxSizer "mark_wxSizer"; + + </ins><span class="cx"> %import "include/wxObject.h" </span><span class="cx"> %import "include/wxSizer.h" </span><span class="cx"> </span></span></pre>&l...
2007 Jul 04
0
[1108] trunk/wxruby2/swig: Revised mem mgmt for Sizers to address more GC crashes in Sizers demo
...<span class="cx"> </span><span class="cx"> </span><del>-// shared functions for GC marking </del><ins>+// shared functions </ins><span class="cx"> %include "../shared/sizers.i" </span><del>-%markfunc wxBoxSizer "mark_wxSizer"; </del><span class="cx"> </span><del>- </del><span class="cx"> %import "include/wxObject.h" </span><span class="cx"> %import "include/wxSizer.h" </span><sp...
2007 May 22
0
[1032] trunk/wxruby2/swig: Preserve Sizers associated with Windows from GC; fix several sample
...lt;span class="cx"> %define GC_MANAGE_AS_WINDOW(kls) </span><span class="cx"> GC_NEVER(kls); </span><ins>+ +// Any sizer associated with the frame will be preserved by the default +// function. If subclasse of Wx::Window need to implement their own +// markfuncs (eg controls with ItemData), they probably need to call +// this function in their own mark routine if they may have a sizer +// associated with them. +%feature("markfunc") kls "GC_mark_wxWindow"; </ins><span class="cx"> %enddef </span><span class...
2007 Jun 26
0
[1087] trunk/wxruby2/swig/classes/StaticBoxSizer.i: Fix a dopey typo introduced recently
...><span class="lines">@@ -8,7 +8,7 @@ </span><span class="cx"> </span><span class="cx"> // shared functions for GC marking </span><span class="cx"> %include "../shared/sizers.i" </span><del>-%markfunc wxBoxSizer "mark_wxSizer"; </del><ins>+%markfunc wxStaticBoxSizer "mark_wxSizer"; </ins><span class="cx"> </span><span class="cx"> // Must ensure that the C++ detach method is called, else the associated </span><s...
2007 Jun 26
0
[1079] trunk/wxruby2/swig/classes/StaticBoxSizer.i: Fix a misnamed function accidentally added in SVN:1077
...><span class="lines">@@ -8,7 +8,7 @@ </span><span class="cx"> </span><span class="cx"> // shared functions for GC marking </span><span class="cx"> %include "../shared/sizers.i" </span><del>-%markfunc wxBoxSizer "mark_wxSBSizer"; </del><ins>+%markfunc wxBoxSizer "mark_wxSizer"; </ins><span class="cx"> </span><span class="cx"> // Must ensure that the C++ detach method is called, else the associated </span><span...
2006 Dec 13
1
0.0.38 tag and release
...ter some work on Weft I''m wondering if these are responsible for a good chunk of problems. Unfortunately I don''t think the solution is as simple as just using DISOWN - but I''d be interested to hear what you think. I''m planning to try and fix this stuff using %markfunc so it works flexibly with ruby''s GC - Add Scintilla for Linux - Roy, sorry, this patch just dropped off my screen. It''s compiling fine but just not appearing in bigdemo. Hopefully something simple. - Have another go at DataObject using a C++ subclass... - Try and nail some of...
2007 Jun 26
0
[1077] trunk/wxruby2/swig/classes/StaticBoxSizer.i: Avoid crash-on-exit with StatBoxSizer by removing some unnec director methods
...gt;<span class="lines">@@ -8,8 +8,15 @@ </span><span class="cx"> </span><span class="cx"> // shared functions for GC marking </span><span class="cx"> %include "../shared/sizers.i" </span><del>-%markfunc wxBoxSizer "mark_wxSizer"; </del><ins>+%markfunc wxBoxSizer "mark_wxSBSizer"; </ins><span class="cx"> </span><ins>+// Must ensure that the C++ detach method is called, else the associated +// StaticBox will be double-freed +%feature...
2006 Nov 23
0
[748] trunk/wxruby2/swig/classes: Fix an errant Ruby-ism in C++ code (Roy Sutton)
...p;nbsp2006-11-21 22:30:19 UTC (rev 747) +++ trunk/wxruby2/swig/classes/Choice.i&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp2006-11-23 00:13:04 UTC (rev 748) </span><span class="lines">@@ -33,7 +33,7 @@ </span><span class="cx"> %markfunc wxChoice "mark_wxControlWithItems"; </span><span class="cx"> </span><span class="cx"> %extend wxChoice { </span><del>- VALUE get_client_data(int n) { wxControlWithItems_get_client_data(self, n); } </del><ins>+ VALUE ge...
2006 Nov 21
0
[744] trunk/wxruby2: get_data support & mem mgmt to all ControlWithItems types, using more
...Str); </span><span class="cx"> </span><del>- </del><span class="cx"> // start client_data fixes </span><span class="cx"> %include "../shared/control_with_items.i" </span><span class="cx"> %markfunc wxChoice "mark_wxControlWithItems"; </span><span class="cx"> </span><del>-%ignore wxChoice::GetClientData(int n) const; -%ignore wxChoice::GetClientObject(int n) const; </del><span class="cx"> %extend wxChoice { </span><del...
2006 Nov 01
1
get_client_data
As a first stab at understanding swig''s mem mgmt features, I tried to fix get_client_data, using Wx::Choice as a testbed. The attached patch resolves the immediate crasher with this function (which was b/c the typemap for void* isn''t right for this method). It also uses the %markfunc feature to prevent objects that are set as client data from being GC''d. The mini-script attached exercises both these issues. It works for me, but there''s still a few issues: 1) Ideally we would implement this in ControlWithItems - but that''s an abstract class, and th...
2007 Jul 21
0
[1135] trunk/wxruby2/swig/mark_free_impl.i: Convert from DOS to Unix newlines
...routine. 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 it is still accessible on screen, -// because it may still handle events. Rather than a SWIG %markfunc, -// which can catch destroyed MenuBars linked to an in-scope ruby -// variable and cause segfaults, MenuBars are always marked via the -// containing Frame. -void GC_mark_MenuBarBelongingToFrame(wxMenuBar *menu_bar) -{ - rb_gc_mark( SWIG_RubyInstanceFor(menu_bar) ); - // Mark each menu in the m...
2007 Jul 21
0
[1127] trunk/wxruby2: Move shared C++ GC functions into separate file included into wx.i
...routine. 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 it is still accessible on screen, +// because it may still handle events. Rather than a SWIG %markfunc, +// which can catch destroyed MenuBars linked to an in-scope ruby +// variable and cause segfaults, MenuBars are always marked via the +// containing Frame. +void GC_mark_MenuBarBelongingToFrame(wxMenuBar *menu_bar) +{ + rb_gc_mark( SWIG_RubyInstanceFor(menu_bar) ); + // Mark each menu in the m...
2008 Apr 13
3
fxruby gem install problem
...-fno-strict-aliasing -g -O2 -fPIC -O0 -Iinclude -c layout_wrap.cpp g++ -I. -I. -I/usr/lib/ruby/1.8/i486-linux -I. -DHAVE_SYS_TIME_H -DHAVE_SIGNAL_H -I/usr/local/include/fxscintilla -I/usr/local/include/fox-1.6 -I/usr/include/fox-1.6 -fPIC -fno-strict-aliasing -g -O2 -fPIC -O0 -Iinclude -c markfuncs.cpp g++ -I. -I. -I/usr/lib/ruby/1.8/i486-linux -I. -DHAVE_SYS_TIME_H -DHAVE_SIGNAL_H -I/usr/local/include/fxscintilla -I/usr/local/include/fox-1.6 -I/usr/include/fox-1.6 -fPIC -fno-strict-aliasing -g -O2 -fPIC -O0 -Iinclude -c dc_wrap.cpp g++ -I. -I. -I/usr/lib/ruby/1.8/i486-linux -I. -DHAV...
2007 Jul 19
0
[1122] trunk/wxruby2/swig/classes/PrintPreview.i: Mark the PrintOuts associated with a Preview to prevent premature
...; +&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbspwxPrintout* printout_for_printing = print_preview->GetPrintoutForPrinting(); +&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsprb_gc_mark( SWIG_RubyInstanceFor(printout_for_printing) ); + } +%} + +%markfunc wxPrintPreview "mark_wxPrintPreview"; + </ins><span class="cx"> %import "include/wxObject.h" </span><span class="cx"> </span><span class="cx"> %include "include/wxPrintPreview.h" </span></span&...
2007 Mar 27
0
[920] branches/wxruby2/wxwidgets_282/swig/classes/TreeCtrl.i: Fix compile error: TreeCtrl no longer inherits from wxScrolledWindow on GTK/Mac
...282/swig/classes/TreeCtrl.i&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp2007-03-27 17:54:41 UTC (rev 920) </span><span class="lines">@@ -98,19 +98,12 @@ </span><span class="cx"> %} </span><span class="cx"> %markfunc wxTreeCtrl "mark_wxTreeCtrl"; </span><span class="cx"> </span><del>-%import "include/wxObject.h" -%import "include/wxEvtHandler.h" -%import "include/wxWindow.h" - -#if defined(__WXMSW__) </del><span class="cx&q...
2006 Dec 23
0
[797] trunk/wxruby2/swig/classes/TreeCtrl.i: Traverse method moved to wxSugar
...bsp&nbspVALUE rb_item_id = SWIG_NewPointerObj(copy_id, SWIGTYPE_p_wxTreeItemId, SWIG_POINTER_OWN); -&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsprb_yield(rb_item_id); - } </del><span class="cx"> %} </span><span class="cx"> %markfunc wxTreeCtrl "mark_wxTreeCtrl"; </span><span class="cx"> </span><span class="lines">@@ -116,24 +108,6 @@ </span><span class="cx"> </span><span class="cx"> </span><span class="cx"&gt...
2007 May 22
0
[1029] trunk/wxruby2/swig/classes/MenuBar.i: Add special GC protection for Wx::Menu to prevent premature destruction
...mp;nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp VALUE rb_menu = SWIG_RubyInstanceFor(menu); +&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp rb_gc_mark(rb_menu); +&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp} +} +%} + +%markfunc wxMenuBar "mark_wxMenuBar"; + </ins><span class="cx"> %import "include/wxObject.h" </span><span class="cx"> %import "include/wxEvtHandler.h" </span><ins>+%import "include/wxWindow.h" </ins><span...
2007 Jun 28
0
[1092] trunk/wxruby2/swig/classes/App.i: Pass correctly typed Events into filter_event, if defined (bug 10797);
...sp&nbsp&nbsp&nbsp} </span><span class="cx"> </span><span class="cx"> }; </span><del>- </del><span class="cx"> %} </span><span class="cx"> </span><span class="cx"> %markfunc wxRubyApp "wxRubyApp::mark_wxRubyApp"; </span></span></pre> </div> </div> </body> </html>