vcl/source/app/timer.cxx | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
New commits: commit 458f01c577c5340e07b345d228fe3d847cc6a5b1 Author: Michael Meeks <michael.me...@collabora.com> Date: Wed Nov 25 21:06:59 2015 +0000 vcl: timer - avoid expensive and pointless re-fetch of current time. Change-Id: I1423de820ec40340d2ddb9030106b813e488f2f3 Reviewed-on: https://gerrit.libreoffice.org/20184 Reviewed-by: Michael Meeks <michael.me...@collabora.com> Tested-by: Michael Meeks <michael.me...@collabora.com> diff --git a/vcl/source/app/timer.cxx b/vcl/source/app/timer.cxx index f5ec1b2..cb00fab 100644 --- a/vcl/source/app/timer.cxx +++ b/vcl/source/app/timer.cxx @@ -38,7 +38,6 @@ bool Timer::ReadyForSchedule( bool /* bTimerOnly */ ) const sal_uInt64 Timer::UpdateMinPeriod( sal_uInt64 nMinPeriod, sal_uInt64 nTime ) const { - const sal_uInt64 nNewTime = tools::Time::GetSystemTicks(); sal_uInt64 nDeltaTime; //determine smallest time slot if( mpSchedulerData->mnUpdateTime == nTime ) @@ -50,11 +49,11 @@ sal_uInt64 Timer::UpdateMinPeriod( sal_uInt64 nMinPeriod, sal_uInt64 nTime ) con else { nDeltaTime = mpSchedulerData->mnUpdateTime + mnTimeout; - if( nDeltaTime < nNewTime ) + if( nDeltaTime < nTime ) nMinPeriod = ImmediateTimeoutMs; else { - nDeltaTime -= nNewTime; + nDeltaTime -= nTime; if( nDeltaTime < nMinPeriod ) nMinPeriod = nDeltaTime; } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits