summaryrefslogtreecommitdiff
path: root/sfx2/source/doc/guisaveas.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sfx2/source/doc/guisaveas.cxx')
-rw-r--r--sfx2/source/doc/guisaveas.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/sfx2/source/doc/guisaveas.cxx b/sfx2/source/doc/guisaveas.cxx
index 606afe80fe4e..ff02c3c442ea 100644
--- a/sfx2/source/doc/guisaveas.cxx
+++ b/sfx2/source/doc/guisaveas.cxx
@@ -671,6 +671,10 @@ sal_Int8 ModelData_Impl::CheckSaveAcceptable( sal_Int8 nCurStatus )
//-------------------------------------------------------------------------
sal_Int8 ModelData_Impl::CheckStateForSave()
{
+ // if the document is readonly or a new one a SaveAs operation must be used
+ if ( !GetStorable()->hasLocation() || GetStorable()->isReadonly() )
+ return STATUS_SAVEAS;
+
// check acceptable entries for media descriptor
sal_Bool bVersInfoNeedsStore = sal_False;
::comphelper::SequenceAsHashMap aAcceptedArgs;
@@ -707,10 +711,6 @@ sal_Int8 ModelData_Impl::CheckStateForSave()
return STATUS_NO_ACTION;
}
- // if the document is readonly or a new one a SaveAs operation must be used
- if ( !GetStorable()->hasLocation() || GetStorable()->isReadonly() )
- return STATUS_SAVEAS;
-
// check that the old filter is acceptable
::rtl::OUString aOldFilterName = GetDocProps().getUnpackedValueOrDefault(
aFilterNameString,