Kaydet (Commit) fe9e4ef7 authored tarafından Cédric Bosdonnat's avatar Cédric Bosdonnat

Fixed crash when selecting objs anchored at page

üst 5b8e7ef7
......@@ -1196,12 +1196,15 @@ sal_Bool SwFEShell::ShouldObjectBeSelected(const Point& rPt)
// Don't select header / footer objects in body edition and vice-versa
SwContact* pContact = static_cast<SwContact*>(pObj->GetUserCall());
const SwPosition& rPos = pContact->GetCntntAnchor();
bool bInHdrFtr = GetDoc()->IsInHeaderFooter( rPos.nNode );
if ( ( IsHeaderFooterEdit() && !bInHdrFtr ) ||
( !IsHeaderFooterEdit() && bInHdrFtr ) )
if ( !pContact->ObjAnchoredAtPage() )
{
bRet = sal_False;
const SwPosition& rPos = pContact->GetCntntAnchor();
bool bInHdrFtr = GetDoc()->IsInHeaderFooter( rPos.nNode );
if ( ( IsHeaderFooterEdit() && !bInHdrFtr ) ||
( !IsHeaderFooterEdit() && bInHdrFtr ) )
{
bRet = sal_False;
}
}
if ( bRet )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment