summaryrefslogtreecommitdiff
path: root/sfx2/source/view/viewfrm.cxx
diff options
context:
space:
mode:
authorOliver Bolte <obo@openoffice.org>2005-03-15 10:48:59 +0000
committerOliver Bolte <obo@openoffice.org>2005-03-15 10:48:59 +0000
commitcefd260a88175ab12abfba91cd96646e3a938d56 (patch)
treeec58656f49b2169e82799222ceaa3bbe535419af /sfx2/source/view/viewfrm.cxx
parent509fd5b35a9dc73fb779089dd232071a6278360b (diff)
INTEGRATION: CWS mav17 (1.105.8); FILE MERGED
2005/03/04 10:21:45 mav 1.105.8.1: #i43774# macro security adjustments
Diffstat (limited to 'sfx2/source/view/viewfrm.cxx')
-rw-r--r--sfx2/source/view/viewfrm.cxx18
1 files changed, 11 insertions, 7 deletions
diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx
index 016c53b49c41..8c52395e61e0 100644
--- a/sfx2/source/view/viewfrm.cxx
+++ b/sfx2/source/view/viewfrm.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: viewfrm.cxx,v $
*
- * $Revision: 1.107 $
+ * $Revision: 1.108 $
*
- * last change: $Author: kz $ $Date: 2005-03-04 00:20:30 $
+ * last change: $Author: obo $ $Date: 2005-03-15 11:48:59 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -4056,12 +4056,16 @@ SfxMacro* SfxViewFrame::GetRecordingMacro_Impl()
void SfxViewFrame::UpdateDocument_Impl()
{
SfxObjectShell* pDoc = GetObjectShell();
- if ( pDoc->HasMacrosLib_Impl() || pDoc->HasMacrosStor_Impl() )
- pDoc->AdjustMacroMode( String() );
- else
+ if ( pDoc->IsLoadingFinished() )
{
- // if macros will be added by the user later, the security check is obsolete
- pDoc->Get_Impl()->nMacroMode = ::com::sun::star::document::MacroExecMode::ALWAYS_EXECUTE_NO_WARN;
+ // if the loading still not finished the macros will be handled immediatelly after loading
+ if ( pDoc->HasMacrosLib_Impl() || pDoc->HasMacrosStor_Impl() )
+ pDoc->AdjustMacroMode( String() );
+ else
+ {
+ // if macros will be added by the user later, the security check is obsolete
+ pDoc->Get_Impl()->nMacroMode = ::com::sun::star::document::MacroExecMode::ALWAYS_EXECUTE_NO_WARN;
+ }
}
// check if document depends from a template