Tag: cws_dev300_odbmacros3
User: fs      
Date: 2008-08-05 11:07:56+0000
Modified:
   dba/dbaccess/source/core/dataaccess/documenteventexecutor.cxx

Log:
 #i83816# when dispatching the script URL, pass the DocumentEvent instance, for 
use by the script

File Changes:

Directory: /dba/dbaccess/source/core/dataaccess/
================================================

File [changed]: documenteventexecutor.cxx
Url: 
http://dba.openoffice.org/source/browse/dba/dbaccess/source/core/dataaccess/documenteventexecutor.cxx?r1=1.1.2.5&r2=1.1.2.6
Delta lines:  +7 -4
-------------------
--- documenteventexecutor.cxx   2008-07-29 20:21:34+0000        1.1.2.5
+++ documenteventexecutor.cxx   2008-08-05 11:07:53+0000        1.1.2.6
@@ -7,7 +7,7 @@
 *
 * $RCSfile: documenteventexecutor.cxx,v $
 *
-* $Revision: 1.1.2.5 $
+* $Revision: 1.1.2.6 $
 *
 * This file is part of OpenOffice.org.
 *
@@ -96,7 +96,7 @@
     namespace
     {
         static void lcl_dispatchScriptURL_throw( DocumentEventExecutor_Data& 
_rDocExecData,
-            const ::rtl::OUString& _rScriptURL )
+            const ::rtl::OUString& _rScriptURL, const DocumentEvent& _rTrigger 
)
         {
             // unfortunately, executing a script can trigger all kind of 
complex stuff, and unfortunately, not
             // every component involved into this properly cares for thread 
safety. To be on the safe side,
@@ -127,7 +127,10 @@
                 return;
             }
 
-            xDispatch->dispatch( aScriptURL, Sequence< PropertyValue >() );
+            PropertyValue aEventParam;
+            aEventParam.Value <<= _rTrigger;
+            Sequence< PropertyValue > aDispatchArgs( &aEventParam, 1 );
+            xDispatch->dispatch( aScriptURL, aDispatchArgs );
         }
     }
 
@@ -209,7 +212,7 @@
 
             if ( bDispatchScriptURL && bNonEmptyScript )
             {
-                lcl_dispatchScriptURL_throw( *m_pData, sScript );
+                lcl_dispatchScriptURL_throw( *m_pData, sScript, _Event );
             }
         }
         catch( const RuntimeException& ) { throw; }




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to