]> git.saurik.com Git - wxWidgets.git/commitdiff
added support for range types to runtime depersister
authorStefan Csomor <csomor@advancedconcepts.ch>
Wed, 27 Aug 2003 17:11:39 +0000 (17:11 +0000)
committerStefan Csomor <csomor@advancedconcepts.ch>
Wed, 27 Aug 2003 17:11:39 +0000 (17:11 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@23257 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/xtistrm.cpp

index 5f5563cd2100e534cbef9c8983578dc6c7dbbc6c..0c3b09a079821359a75e9f495fa800370683cf3e 100644 (file)
@@ -511,9 +511,22 @@ void wxRuntimeDepersister::SetConnect(int eventSourceObjectID,
 
     if ( ehsource && ehsink )
     {
-        ehsource->Connect( -1 , delegateInfo->GetEventType() ,
-            handlerInfo->GetEventFunction() , NULL /*user data*/ ,
-            ehsink ) ;
+        if( delegateInfo->GetLastEventType() == -1 )
+        {
+            ehsource->Connect( -1 , delegateInfo->GetEventType() ,
+                handlerInfo->GetEventFunction() , NULL /*user data*/ ,
+                ehsink ) ;
+        }
+        else
+        {
+            for ( wxEventType iter = delegateInfo->GetEventType() ; iter <= delegateInfo->GetLastEventType() ; ++iter )
+            {
+                ehsource->Connect( -1 , iter ,
+                    handlerInfo->GetEventFunction() , NULL /*user data*/ ,
+                    ehsink ) ;
+            }
+        }
+        
     }
 }