[Libreoffice-commits] core.git: sc/source
Noel Grandin (via logerrit)
logerrit at kemper.freedesktop.org
Tue May 19 12:44:15 UTC 2020
sc/source/ui/cctrl/tbzoomsliderctrl.cxx | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
New commits:
commit 174f1785c423d268ebf23fba6529714af366fb97
Author: Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Tue May 19 13:49:02 2020 +0200
Commit: Stephan Bergmann <sbergman at redhat.com>
CommitDate: Tue May 19 14:43:32 2020 +0200
fix loplugin:vclwidgets fallout
from "tdf#125538 fix background of zoom control"
Change-Id: I444dea360ab10be6bebfe50a1f7b4d2f555bf59b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/94498
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman at redhat.com>
diff --git a/sc/source/ui/cctrl/tbzoomsliderctrl.cxx b/sc/source/ui/cctrl/tbzoomsliderctrl.cxx
index e6214f8e05e1..24f6a9b8df9c 100644
--- a/sc/source/ui/cctrl/tbzoomsliderctrl.cxx
+++ b/sc/source/ui/cctrl/tbzoomsliderctrl.cxx
@@ -97,7 +97,7 @@ struct ScZoomSlider::ScZoomSliderWnd_Impl
Image maIncreaseButton;
Image maDecreaseButton;
bool mbOmitPaint;
- vcl::Window* mpParentWindow;
+ VclPtr<vcl::Window> mxParentWindow;
explicit ScZoomSliderWnd_Impl( sal_uInt16 nCurrentZoom, vcl::Window* parentWindow ) :
mnCurrentZoom( nCurrentZoom ),
@@ -109,7 +109,7 @@ struct ScZoomSlider::ScZoomSliderWnd_Impl
maIncreaseButton(),
maDecreaseButton(),
mbOmitPaint( false ),
- mpParentWindow(parentWindow)
+ mxParentWindow(parentWindow)
{
}
};
@@ -278,7 +278,7 @@ bool ScZoomSlider::MouseButtonDown( const MouseEvent& rMEvt )
return true;
// need to invalidate parent since we rely on the toolbox drawing it's fancy gradient background
- mpImpl->mpParentWindow->Invalidate();
+ mpImpl->mxParentWindow->Invalidate();
mpImpl->mbOmitPaint = true;
SvxZoomSliderItem aZoomSliderItem( mpImpl->mnCurrentZoom );
@@ -313,7 +313,7 @@ bool ScZoomSlider::MouseMove( const MouseEvent& rMEvt )
mpImpl->mnCurrentZoom = Offset2Zoom( aPoint.X() );
// need to invalidate parent since we rely on the toolbox drawing it's fancy gradient background
- mpImpl->mpParentWindow->Invalidate();
+ mpImpl->mxParentWindow->Invalidate();
mpImpl->mbOmitPaint = true; // optimization: paint before executing command,
@@ -381,7 +381,7 @@ void ScZoomSlider::UpdateFromItem(const SvxZoomSliderItem* pZoomSliderItem)
if ( !mpImpl->mbOmitPaint )
// need to invalidate parent since we rely on the toolbox drawing it's fancy gradient background
- mpImpl->mpParentWindow->Invalidate();
+ mpImpl->mxParentWindow->Invalidate();
}
void ScZoomSlider::Paint(vcl::RenderContext& rRenderContext, const tools::Rectangle& /*rRect*/)
More information about the Libreoffice-commits
mailing list