diff options
author | Luboš Luňák <l.lunak@suse.cz> | 2013-07-12 18:12:34 +0200 |
---|---|---|
committer | Luboš Luňák <l.lunak@suse.cz> | 2013-07-12 20:57:58 +0200 |
commit | 2cca46d54846b0cd7769b9287f17632a4258256d (patch) | |
tree | d0a6fa638d4e4afdbb93ee83c9afd46723f467e1 /sc/source/filter/oox/unitconverter.cxx | |
parent | 5e28f6e9d3021171b12a7827cd5c93cfda1fcd90 (diff) |
PCH for more libraries
Change-Id: I6f9a1969605e0016b11157ddb5754ac77fd3966b
Diffstat (limited to 'sc/source/filter/oox/unitconverter.cxx')
-rw-r--r-- | sc/source/filter/oox/unitconverter.cxx | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/sc/source/filter/oox/unitconverter.cxx b/sc/source/filter/oox/unitconverter.cxx index 20d9c487258c..780168c9760e 100644 --- a/sc/source/filter/oox/unitconverter.cxx +++ b/sc/source/filter/oox/unitconverter.cxx @@ -67,7 +67,7 @@ void lclSkipYearBlock( sal_Int32& ornDays, sal_Int16& ornYear, sal_Int32 nDaysIn /** Returns the number of days before the passed date, starting from the null date 0000-Jan-01, using standard leap year conventions. */ -sal_Int32 lclGetDays( const Date& rDate ) +sal_Int32 lclGetDays( const css::util::Date& rDate ) { // number of days in all full years before passed date including all leap days sal_Int32 nDays = rDate.Year * 365 + ((rDate.Year + 3) / 4) - ((rDate.Year + 99) / 100) + ((rDate.Year + 399) / 400); @@ -98,7 +98,7 @@ sal_Int32 lclGetDays( const Date& rDate ) UnitConverter::UnitConverter( const WorkbookHelper& rHelper ) : WorkbookHelper( rHelper ), maCoeffs( UNIT_ENUM_SIZE, 1.0 ), - mnNullDate( lclGetDays( Date( 30, 12, 1899 ) ) ) + mnNullDate( lclGetDays( css::util::Date( 30, 12, 1899 ) ) ) { // initialize constant and default coefficients const DeviceInfo& rDeviceInfo = getBaseFilter().getGraphicHelper().getDeviceInfo(); @@ -157,7 +157,7 @@ void UnitConverter::finalizeImport() } } -void UnitConverter::finalizeNullDate( const Date& rNullDate ) +void UnitConverter::finalizeNullDate( const css::util::Date& rNullDate ) { // convert the nulldate to number of days since 0000-Jan-01 mnNullDate = lclGetDays( rNullDate ); @@ -180,17 +180,17 @@ double UnitConverter::scaleFromMm100( sal_Int32 nMm100, Unit eUnit ) const return static_cast< double >( nMm100 ) / getCoefficient( eUnit ); } -double UnitConverter::calcSerialFromDateTime( const DateTime& rDateTime ) const +double UnitConverter::calcSerialFromDateTime( const css::util::DateTime& rDateTime ) const { - sal_Int32 nDays = lclGetDays( Date( rDateTime.Day, rDateTime.Month, rDateTime.Year ) ) - mnNullDate; + sal_Int32 nDays = lclGetDays( css::util::Date( rDateTime.Day, rDateTime.Month, rDateTime.Year ) ) - mnNullDate; OSL_ENSURE( nDays >= 0, "UnitConverter::calcDateTimeSerial - invalid date" ); OSL_ENSURE( (rDateTime.Hours <= 23) && (rDateTime.Minutes <= 59) && (rDateTime.Seconds <= 59), "UnitConverter::calcDateTimeSerial - invalid time" ); return nDays + rDateTime.Hours / 24.0 + rDateTime.Minutes / 1440.0 + rDateTime.Seconds / 86400.0; } -DateTime UnitConverter::calcDateTimeFromSerial( double fSerial ) const +css::util::DateTime UnitConverter::calcDateTimeFromSerial( double fSerial ) const { - DateTime aDateTime( 0, 0, 0, 0, 1, 1, 0 ); + css::util::DateTime aDateTime( 0, 0, 0, 0, 1, 1, 0 ); double fDays = 0.0; double fTime = modf( fSerial, &fDays ); |