[Libreoffice-commits] core.git: vcl/source
Caolán McNamara
caolanm at redhat.com
Tue Aug 29 11:45:30 UTC 2017
vcl/source/window/status.cxx | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
New commits:
commit 4b44a42b6a54ddf57635fcdb9cf9c18c5e631ff1
Author: Caolán McNamara <caolanm at redhat.com>
Date: Tue Aug 29 10:00:38 2017 +0100
Resolves: tdf#111865 ensure draw after SetProgressValue uses new value
and always erase the background so we can go backwards as well as forwards
Change-Id: Ibdf215320d0eeb3392cd21d3e1fd5c0535e6cd31
Reviewed-on: https://gerrit.libreoffice.org/41675
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/vcl/source/window/status.cxx b/vcl/source/window/status.cxx
index 131483888f31..3829a5aa99bf 100644
--- a/vcl/source/window/status.cxx
+++ b/vcl/source/window/status.cxx
@@ -1373,15 +1373,15 @@ void StatusBar::SetProgressValue( sal_uInt16 nNewPercent )
SAL_WARN_IF( !mbProgressMode, "vcl", "StatusBar::SetProgressValue(): no progress mode" );
SAL_WARN_IF( nNewPercent > 100, "vcl", "StatusBar::SetProgressValue(): nPercent > 100" );
- if ( mbProgressMode
- && IsReallyVisible()
- && (!mnPercent || (mnPercent != nNewPercent)) )
+ bool bInvalidate = mbProgressMode && IsReallyVisible() && (!mnPercent || (mnPercent != nNewPercent));
+
+ mnPercent = nNewPercent;
+
+ if (bInvalidate)
{
- bool bNeedErase = ImplGetSVData()->maNWFData.mbProgressNeedsErase;
- Invalidate(maPrgsFrameRect, bNeedErase ? InvalidateFlags::NONE : InvalidateFlags::NoErase);
+ Invalidate(maPrgsFrameRect);
Update();
}
- mnPercent = nNewPercent;
}
void StatusBar::EndProgressMode()
More information about the Libreoffice-commits
mailing list