restore SdrMarkView::HasMarkableObj, etc.

Change-Id: Ib5c0d5028792708bc0ac0e756aa47d486443bbb7
This commit is contained in:
Caolán McNamara 2013-12-02 16:00:10 +00:00
parent c27c01e248
commit 4bcd960e7f
2 changed files with 21 additions and 0 deletions

View File

@ -228,6 +228,8 @@ public:
void SetFrameDragSingles(sal_Bool bOn=sal_True) { SetFrameHandles(bOn); }
sal_Bool IsFrameDragSingles() const { return IsFrameHandles(); }
sal_Bool HasMarkableObj() const;
////////////////////////////////////////////////////////////////////////////////////////////////////
// migrate selections

View File

@ -519,6 +519,25 @@ sal_uIntPtr SdrMarkView::GetMarkableObjCount() const
return nCount;
}
sal_Bool SdrMarkView::HasMarkableObj() const
{
sal_uIntPtr nCount=0;
SdrPageView* pPV = GetSdrPageView();
if(pPV)
{
SdrObjList* pOL=pPV->GetObjList();
sal_uIntPtr nObjAnz=pOL->GetObjCount();
for (sal_uIntPtr nObjNum=0; nObjNum<nObjAnz && nCount==0; nObjNum++) {
SdrObject* pObj=pOL->GetObj(nObjNum);
if (IsObjMarkable(pObj,pPV)) {
nCount++;
}
}
}
return nCount!=0;
}
void SdrMarkView::hideMarkHandles()
{
if(!mbMarkHandlesHidden)