sd/source/ui/view/drviews5.cxx | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)
New commits: commit d9b73c3579cb6a16bb82c0e0e1643ae0893c52e5 Author: Tünde Tóth <toth.tu...@nisz.hu> AuthorDate: Wed Oct 19 13:07:42 2022 +0200 Commit: Xisco Fauli <xiscofa...@libreoffice.org> CommitDate: Wed Nov 2 11:00:44 2022 +0100 tdf#151621 sd UI: use correct zoom in embedded PPTX Embedded PPTX object opened at 3000% zoom in a new window. Change-Id: I7b353b607a1cef84eceaac5fbff96f2fbeb18500 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/141528 Tested-by: László Németh <nem...@numbertext.org> Reviewed-by: László Németh <nem...@numbertext.org> (cherry picked from commit 6e378b5beee473edc54c50550eff9e7d9eec57b5) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142143 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org> diff --git a/sd/source/ui/view/drviews5.cxx b/sd/source/ui/view/drviews5.cxx index 9c00365be2c2..3eb9f39c376f 100644 --- a/sd/source/ui/view/drviews5.cxx +++ b/sd/source/ui/view/drviews5.cxx @@ -82,9 +82,11 @@ void DrawViewShell::Resize() { ViewShell::Resize(); - if ( GetDocSh()->GetCreateMode() == SfxObjectCreateMode::EMBEDDED ) + // tdf#151621 Do not set if the embedded object is opening in a new window. + if (GetDocSh()->GetCreateMode() == SfxObjectCreateMode::EMBEDDED + && GetDocSh()->IsInPlaceActive()) { - SetZoomRect( GetDocSh()->GetVisArea(ASPECT_CONTENT) ); + SetZoomRect(GetDocSh()->GetVisArea(ASPECT_CONTENT)); } rtl::Reference< sd::SlideShow > xSlideshow( SlideShow::GetSlideShow( GetViewShellBase() ) ); @@ -545,7 +547,9 @@ void DrawViewShell::ReadUserDataSequence ( const css::uno::Sequence < css::beans { const ::tools::Rectangle aVisArea( mpFrameView->GetVisArea() ); - if ( GetDocSh()->GetCreateMode() == SfxObjectCreateMode::EMBEDDED ) + // tdf#151621 Do not set if the embedded object is opening in a new window. + if (GetDocSh()->GetCreateMode() == SfxObjectCreateMode::EMBEDDED + && GetDocSh()->IsInPlaceActive()) { GetDocSh()->SetVisArea(aVisArea); }