summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
Diffstat (limited to 'svx')
-rw-r--r--svx/source/svdraw/svdviter.cxx95
1 files changed, 43 insertions, 52 deletions
diff --git a/svx/source/svdraw/svdviter.cxx b/svx/source/svdraw/svdviter.cxx
index f7bc7005d9a9..1078dc76a1b9 100644
--- a/svx/source/svdraw/svdviter.cxx
+++ b/svx/source/svdraw/svdviter.cxx
@@ -70,71 +70,62 @@ SdrViewIter::SdrViewIter(const SdrObject* pObject, bool bNoMasterPage)
bool SdrViewIter::ImpCheckPageView(SdrPageView* pPV) const
{
- if(mpPage)
- {
- bool bMaster(mpPage->IsMasterPage());
- SdrPage* pPg = pPV->GetPage();
+ if(!mpPage)
+ return true;
- if(pPg == mpPage)
+ bool bMaster(mpPage->IsMasterPage());
+ SdrPage* pPg = pPV->GetPage();
+
+ if(pPg == mpPage)
+ {
+ if(mpObject)
{
- if(mpObject)
- {
- // Looking for an object? First, determine if it visible in
- // this PageView.
- SetOfByte aObjLay;
- mpObject->getMergedHierarchyLayerSet(aObjLay);
- aObjLay &= pPV->GetVisibleLayers();
- return !aObjLay.IsEmpty();
- }
- else
- {
- return true;
- }
+ // Looking for an object? First, determine if it visible in
+ // this PageView.
+ SetOfByte aObjLay;
+ mpObject->getMergedHierarchyLayerSet(aObjLay);
+ aObjLay &= pPV->GetVisibleLayers();
+ return !aObjLay.IsEmpty();
}
else
{
- if(!mbNoMasterPage && bMaster && (!mpObject || !mpObject->IsNotVisibleAsMaster()))
+ return true;
+ }
+ }
+ else if(!mbNoMasterPage && bMaster && (!mpObject || !mpObject->IsNotVisibleAsMaster()))
+ {
+ if(pPg->TRG_HasMasterPage())
+ {
+ SdrPage& rMasterPage = pPg->TRG_GetMasterPage();
+
+ if(&rMasterPage == mpPage)
{
- if(pPg->TRG_HasMasterPage())
+ // the page we're looking for is a master page in this PageView
+ if(mpObject)
{
- SdrPage& rMasterPage = pPg->TRG_GetMasterPage();
-
- if(&rMasterPage == mpPage)
+ // Looking for an object? First, determine if it visible in
+ // this PageView.
+ SetOfByte aObjLay;
+ mpObject->getMergedHierarchyLayerSet(aObjLay);
+ aObjLay &= pPV->GetVisibleLayers();
+ aObjLay &= pPg->TRG_GetMasterPageVisibleLayers();
+
+ if(!aObjLay.IsEmpty())
{
- // the page we're looking for is a master page in this PageView
- if(mpObject)
- {
- // Looking for an object? First, determine if it visible in
- // this PageView.
- SetOfByte aObjLay;
- mpObject->getMergedHierarchyLayerSet(aObjLay);
- aObjLay &= pPV->GetVisibleLayers();
- aObjLay &= pPg->TRG_GetMasterPageVisibleLayers();
-
- if(!aObjLay.IsEmpty())
- {
- return true;
- } // else, look at the next master page of this page...
- }
- else
- {
- return true;
- }
- }
+ return true;
+ } // else, look at the next master page of this page...
+ }
+ else
+ {
+ return true;
}
}
-
- // master page forbidden or no fitting master page found
- return false;
}
}
- else
- {
- return true;
- }
-}
-
+ // master page forbidden or no fitting master page found
+ return false;
+}
SdrView* SdrViewIter::ImpFindView()
{