summaryrefslogtreecommitdiff
path: root/sw/source/core/layout/anchoredobject.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/core/layout/anchoredobject.cxx')
-rw-r--r--sw/source/core/layout/anchoredobject.cxx9
1 files changed, 9 insertions, 0 deletions
diff --git a/sw/source/core/layout/anchoredobject.cxx b/sw/source/core/layout/anchoredobject.cxx
index 0c21a53904b5..5492832663d7 100644
--- a/sw/source/core/layout/anchoredobject.cxx
+++ b/sw/source/core/layout/anchoredobject.cxx
@@ -736,6 +736,15 @@ bool SwAnchoredObject::IsFormatPossible() const
return GetFrameFormat().GetDoc()->getIDocumentDrawModelAccess().IsVisibleLayerId( GetDrawObj()->GetLayer() );
}
+bool SwAnchoredObject::IsDraggingOffPageAllowed(const SwFrameFormat* pFrameFormat)
+{
+ OSL_ASSERT(pFrameFormat);
+ const bool bDisablePositioning = pFrameFormat->getIDocumentSettingAccess().get(DocumentSettingId::DISABLE_OFF_PAGE_POSITIONING);
+ const bool bIsWrapThrough = pFrameFormat->GetSurround().GetSurround() == text::WrapTextMode::WrapTextMode_THROUGH;
+
+ return bDisablePositioning && bIsWrapThrough;
+}
+
// --> #i3317#
void SwAnchoredObject::SetTmpConsiderWrapInfluence( const bool _bTmpConsiderWrapInfluence )
{