search for: eventthunker

Displaying 8 results from an estimated 8 matches for "eventthunker".

2008 Feb 06
0
[ wxruby-Bugs-17827 ] Crash when closing Dialog in bigdemo.rb
...0x000d80da in rb_eval_string_wrap () #18 0x000de178 in rb_thread_trap_eval () #19 0x000de7e6 in rb_thread_trap_eval () #20 0x000da18c in rb_eval_string_wrap () #21 0x000dad6a in rb_eval_string_wrap () #22 0x000db7ed in rb_respond_to () #23 0x000db8d6 in rb_funcall () #24 0x010ab236 in wxRbCallback::EventThunker () at string.h:690 #25 0x0139fbc3 in wxAppConsole::HandleEvent (this=0x3ad2d0, handler=0x833200, func={__pfn = 0x10ab18c <wxRbCallback::EventThunker(wxEvent&)>, __delta = 0}, event=@0xbfffdf24) at ../src/common/appbase.cpp:320 #26 0x0143ba6e in wxEvtHandler::ProcessEventIfMatches (entry=@...
2007 Jun 23
0
[1063] trunk/wxruby2/swig/classes/EvtHandler.i: Add a public ''connect'' method for handling arbitary user-defined events
...ot;new"), 0); + rb_global_variable(&callbacks); + if(callbacks == Qnil) + callbacks = rb_ary_new(); + rb_ary_push(callbacks, func); + + wxObject* userData = new wxRbCallback(func); + wxObjectEventFunction function = + (wxObjectEventFunction )&wxRbCallback::EventThunker; + self->Connect(firstId, lastId, eventType, function, userData); +&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbspreturn Qtrue; + } +} + + +%runtime{ + </ins><span class="cx"> extern swig_class cWxEvtHandler; </span><span class="cx...
2008 May 14
0
[ wxruby-Patches-20130 ] Event handling performance issues
...nt_class_for_type() on the ruby side every time a new event is generated. I modified it to directly access the Wx::EvtHandler::EVENT_TYPE_CLASS_MAP hash (and saving it in a global variable after the first lookup), leading to a great performance improvement. Another minor change was in wxRbCallback::EventThunker, just to avoid repeated calls to rb_intern. After these changes my benchmark script reported an average of 55264 events/second! About 40% increase upon the first mark, quite impressive performance boost with simple changes. :) I''m still looking for a way to reach the ''python lev...
2007 May 12
0
[ wxruby-Bugs-10797 ] App#filter_event always passes Wx::Event
...pp#filter_event always passes Wx::Event Initial Comment: If the App class defines a filter_event method it is correctly called every time an event is generated. However, it always receives an event of class Wx::Event, rather than the appropriate subclass (eg Wx::IdleEvent). We need to hook up the EventThunker code in swig/classes/EvtHandler.i to wrap the C++ objects with the correct class. ---------------------------------------------------------------------- You can respond by visiting: http://rubyforge.org/tracker/?func=detail&atid=218&aid=10797&group_id=35
2005 Sep 19
9
more fixes for Grid classes
I am still hunting the bug where the cell editor finishes and crashes on Mac OS. In the process I have gone over these Grid related classes in great detail and found most were %importing wxObject.h and wxEvtHandler.h and they were not needed. I added a *.i file for ClientDataContainer not sure if it is needed out side Grid. I also added GridCellCoords. Sean
2006 Nov 12
0
[ wxruby-Bugs-6632 ] Linux crash on NoteBook in bigdemo.rb
...ss=3084969020, recv=3063296600, mid=5217, argc=1, argv=0xbf81c6e0, scope=1) at eval.c:6048 #33 0x0805ea27 in vafuncall (recv=3063296600, mid=5217, n=1, ar=0xbf81c754) at eval.c:6125 #34 0x0805eb60 in rb_funcall (recv=3063296600, mid=5217, n=1) at eval.c:6142 #35 0xb76edcd8 in wxRbCallback::EventThunker (this=0x8215fa8, event=@0xbf81cfa0) at src/EvtHandler.cpp:2108 #36 0xb7b5b9be in wxEvtHandler::ProcessEventIfMatches () from lib/wxruby2.so #37 0xb7b5ba52 in wxEvtHandler::SearchDynamicEventTable () from lib/wxruby2.so #38 0xb7b5c3e6 in wxEvtHandler::ProcessEvent () from lib/wxruby2.so #39 0xb...
2007 May 31
0
[1042] trunk/wxruby2: Overhaul of the event handling WxType->RubyClass mapping to make it
...vent and based on the event''s type wraps it in the + // appropriate class (the mapping can be found in + // lib/wx/classes/evthandler.rb). This wrapped event is then passed + // into the ruby proc for handling on the ruby side </ins><span class="cx"> void EventThunker(wxEvent &event) </span><span class="cx"> { </span><del>- VALUE cEvent = Qnil; </del><ins>+ VALUE event_type_id = INT2NUM(event.GetEventType()); + VALUE cEvent = rb_funcall(cWxEvtHandler.klass, +&nbsp&nbsp&nbsp&...
2007 May 29
0
[1035] trunk/wxruby2/swig/classes/EvtHandler.i: Removed a heap of redundant stuff that''s been #if 0''d for a while
...ot;new"), 0); - rb_global_variable(&callbacks); - if(callbacks == Qnil) - callbacks = rb_ary_new(); - rb_ary_push(callbacks, func); - - wxObject* userData = new wxRbCallback(func); - wxObjectEventFunction function = - (wxObjectEventFunction )&wxRbCallback::EventThunker; - (cppSelf)->Connect(firstId, lastId, eventType, function, userData); -} - -static VALUE internal_evt_with_id(int argc, VALUE *argv, VALUE self, - wxEventType eventType) -{ - if (argc != 1) - rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); -...