diff options
author | Mark Hung <marklh9@gmail.com> | 2018-08-22 01:22:31 +0800 |
---|---|---|
committer | Mark Hung <marklh9@gmail.com> | 2018-08-22 12:42:53 +0200 |
commit | dc96b95f4a2c732f678af002bf53765ba3a0a21e (patch) | |
tree | 1544a71008be1526fd38d1fadbea8caf5df82e9a /oox | |
parent | 969e2dd3575bd13813318a4f30e5b06060f3dce3 (diff) |
tdf#119118 convert tmAbs value to second.
setInterval() of IterateContainer actually need second instead
of percentage of the duration, we just need to convert tmAbs
in millisecond to second to make iterate interval correct.
Change-Id: I1dfc3c64187eb5b7fd8f0b6a91f41dc55466b58b
Reviewed-on: https://gerrit.libreoffice.org/59412
Tested-by: Jenkins
Reviewed-by: Mark Hung <marklh9@gmail.com>
Diffstat (limited to 'oox')
-rw-r--r-- | oox/source/ppt/commontimenodecontext.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/oox/source/ppt/commontimenodecontext.cxx b/oox/source/ppt/commontimenodecontext.cxx index 26ea235d898d..cae060f4ca22 100644 --- a/oox/source/ppt/commontimenodecontext.cxx +++ b/oox/source/ppt/commontimenodecontext.cxx @@ -647,14 +647,14 @@ OUString getConvertedSubType( sal_Int16 nPresetClass, sal_Int32 nPresetId, sal_I case PPT_TOKEN( tmAbs ): if( mbIterate ) { - double fTime = rAttribs.getUnsigned( XML_val, 0 ); - // time in ms. property is in % TODO - mpNode->getNodeProperties()[ NP_ITERATEINTERVAL ] <<= fTime; + double fTime = rAttribs.getUnsigned( XML_val, 0 ) / 1000.0; // convert ms. to second. + mpNode->getNodeProperties()[NP_ITERATEINTERVAL] <<= fTime; } return this; case PPT_TOKEN( tmPct ): if( mbIterate ) { + // TODO: should use duration to get iterate interval in second. double fPercent = static_cast<double>(rAttribs.getUnsigned( XML_val, 0 )) / 100000.0; mpNode->getNodeProperties()[ NP_ITERATEINTERVAL ] <<= fPercent; } |