diff options
author | Regina Henschel <rb.henschel@t-online.de> | 2018-09-01 13:03:29 +0200 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2018-09-01 22:38:08 +0200 |
commit | d59acca8d1e33585d6f29cd85e8cb0d598067f9b (patch) | |
tree | 6cd77441cf4f03edc750d8b2484d42b1248806d6 /svx/source/svdraw | |
parent | a9db401c6d3d7089f91940745c94648672bc663f (diff) |
tdf#119611 Use generic SetAll() in SdrPageView ctor.
The LayerAdmin has invalid values in case of charts. In
consequence a bitfield with only zeros was generated,
meaning all is invisible and not printable.
Change-Id: I59d341ac8742f81b5f9afb28dc9add459a01525f
Reviewed-on: https://gerrit.libreoffice.org/59895
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'svx/source/svdraw')
-rw-r--r-- | svx/source/svdraw/svdpagv.cxx | 46 |
1 files changed, 6 insertions, 40 deletions
diff --git a/svx/source/svdraw/svdpagv.cxx b/svx/source/svdraw/svdpagv.cxx index bbb0d8e19e99..1aa17c27d7f7 100644 --- a/svx/source/svdraw/svdpagv.cxx +++ b/svx/source/svdraw/svdpagv.cxx @@ -143,47 +143,13 @@ SdrPageView::SdrPageView(SdrPage* pPage1, SdrView& rNewView) { aPgOrg.setX(mpPage->GetLeftBorder() ); aPgOrg.setY(mpPage->GetUpperBorder() ); - - // Get layersets from document, master page or page to be ODF conform. - // Currently only partly implemented, the comments show, what is missing. - const SdrLayerAdmin& rPageLayerAdmin( mpPage->GetLayerAdmin() ); - if ( rPageLayerAdmin.GetLayerCount() == 0 ) - { - // if (master page has layers) - // Get LayerIDSet from master page. - // else - // Get default LayerIDSet from document - // Currently the parent LayerAdmin is the LayerAdmin of the document - SdrLayerAdmin* pParentLayerAdmin = rPageLayerAdmin.GetParent(); - if ( pParentLayerAdmin ) - { - pParentLayerAdmin->getVisibleLayersODF( aLayerVisi ); - pParentLayerAdmin->getPrintableLayersODF( aLayerPrn ); - pParentLayerAdmin->getLockedLayersODF( aLayerLock ); - } - else - { - // This should not happen. ToDo: assertion for debug mode - aLayerVisi.SetAll(); - aLayerPrn.SetAll(); - } - } - else - { - // page has own Layers. Get LayerIDSet from page, maybe from master page in addition. - rPageLayerAdmin.getVisibleLayersODF( aLayerVisi ); - rPageLayerAdmin.getPrintableLayersODF( aLayerPrn ); - rPageLayerAdmin.getLockedLayersODF( aLayerLock ); - // if (master page has layers) - // Add the layer IDs for master page layers to the set from the page. - } - } - else - { // SdrPageView without page? - // ToDo: assertion for debug mode - aLayerVisi.SetAll(); - aLayerPrn.SetAll(); } + // For example, in the case of charts, there is a LayerAdmin, but it has no valid values. Therefore + // a solution like pLayerAdmin->getVisibleLayersODF(aLayerVisi) is not possible. So use the + // generic SetAll() for now. + aLayerVisi.SetAll(); + aLayerPrn.SetAll(); + mbHasMarked = false; mbVisible = false; pCurrentList = nullptr; |