summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2013-11-18 11:17:31 +0100
committerStephan Bergmann <sbergman@redhat.com>2013-11-18 11:17:47 +0100
commit7f9fde2490610825c77dd1026e4b48c28d496036 (patch)
tree5a72e5f59c6a5b60a69fcbcca08b735d4f43f072
parentdc113e8a86e9904df8f37a2980db39cbabcea78f (diff)
Move SfxFrame::IsAutoLoadLocked_Impl to frame.cxx
Change-Id: I7b5d4a5eeeefa6191cebeada363553c8d6d6d29c
-rw-r--r--sfx2/source/doc/objmisc.cxx20
-rw-r--r--sfx2/source/view/frame.cxx16
2 files changed, 16 insertions, 20 deletions
diff --git a/sfx2/source/doc/objmisc.cxx b/sfx2/source/doc/objmisc.cxx
index f1db22ed7c4b..590f53c145a8 100644
--- a/sfx2/source/doc/objmisc.cxx
+++ b/sfx2/source/doc/objmisc.cxx
@@ -1044,26 +1044,6 @@ void SfxObjectShell::PrepareReload( )
{
}
-// Can be moved to frame.cxx, when 358+36x-State have been merged
-
-sal_Bool SfxFrame::IsAutoLoadLocked_Impl() const
-{
- // Its own Docucument is locked?
- const SfxObjectShell* pObjSh = GetCurrentDocument();
- if ( !pObjSh || !pObjSh->IsAutoLoadLocked() )
- return sal_False;
-
- // Its children are locked?
- for ( sal_uInt16 n = GetChildFrameCount(); n--; )
- if ( !GetChildFrame(n)->IsAutoLoadLocked_Impl() )
- return sal_False;
-
- // otherwise allow AutoLoad
- return sal_True;
-}
-
-//-------------------------------------------------------------------------
-
sal_Bool SfxObjectShell::IsAutoLoadLocked() const
/* Returns whether an Autoload is allowed to be executed. Before the
diff --git a/sfx2/source/view/frame.cxx b/sfx2/source/view/frame.cxx
index e1999d506ed7..f64b7b6b4614 100644
--- a/sfx2/source/view/frame.cxx
+++ b/sfx2/source/view/frame.cxx
@@ -329,6 +329,22 @@ SfxDispatcher* SfxFrame::GetDispatcher_Impl() const
return GetParentFrame()->GetDispatcher_Impl();
}
+sal_Bool SfxFrame::IsAutoLoadLocked_Impl() const
+{
+ // Its own Docucument is locked?
+ const SfxObjectShell* pObjSh = GetCurrentDocument();
+ if ( !pObjSh || !pObjSh->IsAutoLoadLocked() )
+ return sal_False;
+
+ // Its children are locked?
+ for ( sal_uInt16 n = GetChildFrameCount(); n--; )
+ if ( !GetChildFrame(n)->IsAutoLoadLocked_Impl() )
+ return sal_False;
+
+ // otherwise allow AutoLoad
+ return sal_True;
+}
+
SfxObjectShell* SfxFrame::GetCurrentDocument() const
{
return pImp->pCurrentViewFrame ?