diff options
author | Kent Hansen <khansen@trolltech.com> | 2009-07-28 15:32:59 (GMT) |
---|---|---|
committer | Kent Hansen <khansen@trolltech.com> | 2009-07-28 15:32:59 (GMT) |
commit | 14aa95bf83e8fa91151b5edd3c346c20d942eb81 (patch) | |
tree | 46ec6389eb1590e0a018c4acbfba670d315987ba /src/3rdparty/webkit/JavaScriptCore/wtf/DateMath.h | |
parent | 1c72e77e43593dfea6c6392d1058e63762efb534 (diff) | |
parent | f340825f35ad3de28685f4890cd73bbf9bb6c0e6 (diff) | |
download | Qt-14aa95bf83e8fa91151b5edd3c346c20d942eb81.zip Qt-14aa95bf83e8fa91151b5edd3c346c20d942eb81.tar.gz Qt-14aa95bf83e8fa91151b5edd3c346c20d942eb81.tar.bz2 |
Merge branch 'qtwebkit-4.6-staging' into qtscript-jsc-backend
Conflicts:
src/corelib/tools/qregexp.cpp
src/script/qscriptengine.cpp
src/script/qscriptvalue.cpp
Diffstat (limited to 'src/3rdparty/webkit/JavaScriptCore/wtf/DateMath.h')
-rw-r--r-- | src/3rdparty/webkit/JavaScriptCore/wtf/DateMath.h | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/3rdparty/webkit/JavaScriptCore/wtf/DateMath.h b/src/3rdparty/webkit/JavaScriptCore/wtf/DateMath.h index 8690a49..6110f76 100644 --- a/src/3rdparty/webkit/JavaScriptCore/wtf/DateMath.h +++ b/src/3rdparty/webkit/JavaScriptCore/wtf/DateMath.h @@ -109,14 +109,17 @@ struct GregorianDateTime : Noncopyable { , year(inTm.tm_year) , isDST(inTm.tm_isdst) { -#if !PLATFORM(WIN_OS) && !PLATFORM(SOLARIS) && !COMPILER(RVCT) +#if HAVE(TM_GMTOFF) utcOffset = static_cast<int>(inTm.tm_gmtoff); +#else + utcOffset = static_cast<int>(getUTCOffset() / msPerSecond + (isDST ? secondsPerHour : 0)); +#endif +#if HAVE(TM_ZONE) int inZoneSize = strlen(inTm.tm_zone) + 1; timeZone = new char[inZoneSize]; strncpy(timeZone, inTm.tm_zone, inZoneSize); #else - utcOffset = static_cast<int>(getUTCOffset() / msPerSecond + (isDST ? secondsPerHour : 0)); timeZone = 0; #endif } @@ -136,8 +139,10 @@ struct GregorianDateTime : Noncopyable { ret.tm_year = year; ret.tm_isdst = isDST; -#if !PLATFORM(WIN_OS) && !PLATFORM(SOLARIS) && !COMPILER(RVCT) +#if HAVE(TM_GMTOFF) ret.tm_gmtoff = static_cast<long>(utcOffset); +#endif +#if HAVE(TM_ZONE) ret.tm_zone = timeZone; #endif |