Update of /cvsroot/openvrml/openvrml/src/libopenvrml/openvrml
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv32287/src/libopenvrml/openvrml
Modified Files:
Tag: OpenVRML-0_16-BRANCH
browser.cpp
Log Message:
Fixed PROTO eventIn and eventOut lookup functions to try the "set_" prefix and "_changed" suffix (respectively) when looking up event_listener and event_emitter objects.
Index: browser.cpp
===================================================================
RCS file: /cvsroot/openvrml/openvrml/src/libopenvrml/openvrml/browser.cpp,v
retrieving revision 1.190.2.8
retrieving revision 1.190.2.9
diff -C2 -d -r1.190.2.8 -r1.190.2.9
*** browser.cpp 3 Jan 2007 23:43:23 -0000 1.190.2.8
--- browser.cpp 3 Feb 2007 08:22:24 -0000 1.190.2.9
***************
*** 1893,1896 ****
--- 1893,1899 ----
eventin_map_t::iterator pos = this->eventin_map.find(id);
if (pos == this->eventin_map.end()) {
+ pos = this->eventin_map.find("set_" + id);
+ }
+ if (pos == this->eventin_map.end()) {
throw unsupported_interface(this->type(),
node_interface::eventin_id,
***************
*** 1914,1917 ****
--- 1917,1923 ----
eventout_map_t::iterator pos = this->eventout_map.find(id);
if (pos == this->eventout_map.end()) {
+ pos = this->eventout_map.find(id + "_changed");
+ }
+ if (pos == this->eventout_map.end()) {
throw unsupported_interface(this->type(),
node_interface::eventout_id,
|