date/time IDL datatypes incompatible change: fixup
Change-Id: I3733deac232d0075bdd889ce52d7e6f67746d4f8
This commit is contained in:
@@ -224,17 +224,17 @@ void ScOrcusSheet::set_date_time(
|
|||||||
SvNumberFormatter* pFormatter = mrDoc.getDoc().GetFormatTable();
|
SvNumberFormatter* pFormatter = mrDoc.getDoc().GetFormatTable();
|
||||||
|
|
||||||
Date aDate(day, month, year);
|
Date aDate(day, month, year);
|
||||||
sal_uIntPtr nSec = floor(second);
|
sal_uInt32 nSec = floor(second);
|
||||||
sal_uIntPtr nSec100 = (second - nSec) * 100;
|
sal_uInt32 nNanoSec = (second - nSec) * ::Time::nanoSecPerSec;
|
||||||
Time aTime(hour, minute, nSec, nSec100);
|
Time aTime(hour, minute, nSec, nNanoSec);
|
||||||
Date aNullDate(*pFormatter->GetNullDate());
|
Date aNullDate(*pFormatter->GetNullDate());
|
||||||
long nDateDiff = aDate - aNullDate;
|
long nDateDiff = aDate - aNullDate;
|
||||||
|
|
||||||
double fTime =
|
double fTime =
|
||||||
static_cast<double>(aTime.GetNanoSec()) / 1e9 +
|
static_cast<double>(aTime.GetNanoSec()) / ::Time::nanoSecPerSec +
|
||||||
aTime.GetSec() +
|
aTime.GetSec() +
|
||||||
aTime.GetMin() * 60.0 +
|
aTime.GetMin() * ::Time::secondPerMinute +
|
||||||
aTime.GetHour() * 3600.0;
|
aTime.GetHour() * ::Time::secondPerHour;
|
||||||
|
|
||||||
fTime /= DATE_TIME_FACTOR;
|
fTime /= DATE_TIME_FACTOR;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user