summaryrefslogtreecommitdiff
path: root/sw/source/ui/wrtsh/wrtsh2.cxx
diff options
context:
space:
mode:
authorRĂ¼diger Timm <rt@openoffice.org>2004-05-19 07:52:36 +0000
committerRĂ¼diger Timm <rt@openoffice.org>2004-05-19 07:52:36 +0000
commit218395cc6cfc59b0b27de8e6ed5b1bdc6ce78549 (patch)
tree5e2d761e0da7b2a2569362bbdb29746b5eedaa45 /sw/source/ui/wrtsh/wrtsh2.cxx
parent5eacc6b45f5cfd7feeb13cafffe5472ecfabde99 (diff)
INTEGRATION: CWS scriptingf4 (1.16.376); FILE MERGED
2004/04/27 14:10:13 toconnor 1.16.376.1: #i28384# - implement Macro Selector specification
Diffstat (limited to 'sw/source/ui/wrtsh/wrtsh2.cxx')
-rw-r--r--sw/source/ui/wrtsh/wrtsh2.cxx29
1 files changed, 11 insertions, 18 deletions
diff --git a/sw/source/ui/wrtsh/wrtsh2.cxx b/sw/source/ui/wrtsh/wrtsh2.cxx
index 244f27e451..d54627fbc5 100644
--- a/sw/source/ui/wrtsh/wrtsh2.cxx
+++ b/sw/source/ui/wrtsh/wrtsh2.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: wrtsh2.cxx,v $
*
- * $Revision: 1.17 $
+ * $Revision: 1.18 $
*
- * last change: $Author: hr $ $Date: 2004-05-10 16:41:31 $
+ * last change: $Author: rt $ $Date: 2004-05-19 08:52:36 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -387,24 +387,17 @@ void SwWrtShell::ClickToField( const SwField& rFld, USHORT nFilter )
case RES_MACROFLD:
{
const SwMacroField *pFld = (const SwMacroField*)&rFld;
- String sLibName(pFld->GetLibName());
- String sMacroName(pFld->GetMacroName());
+ String sText( rFld.GetPar2() );
+ String sRet( sText );
+ ExecMacro( pFld->GetSvxMacro(), &sRet );
- if( sLibName.Len() && sMacroName.Len() )
+ // return Wert veraendert?
+ if( sRet != sText )
{
- String sText( rFld.GetPar2() );
- String sRet( sText );
- SvxMacro aMacro( sMacroName, sLibName, STARBASIC );
- ExecMacro( aMacro, &sRet );
-
- // return Wert veraendert?
- if( sRet != sText )
- {
- StartAllAction();
- ((SwField&)rFld).SetPar2( sRet );
- ((SwField&)rFld).GetTyp()->UpdateFlds();
- EndAllAction();
- }
+ StartAllAction();
+ ((SwField&)rFld).SetPar2( sRet );
+ ((SwField&)rFld).GetTyp()->UpdateFlds();
+ EndAllAction();
}
}
break;