From 4890c75d0d301fcfea594a5ad80577d0ffa6bb88 Mon Sep 17 00:00:00 2001 From: Edward Welbourne Date: Mon, 9 Nov 2015 12:05:49 +0100 Subject: Prefer "daylight-saving time" and "DST" over "daylight time". MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The first two are the "proper" terms; the last is a colloquialism. Also amended "daylight savings" (which summons to mind a hybrid of "daylight robbery" and "bargain-basket savings"). Improved related wording in many of the places amended. Task-number: QTBUG-49308 Change-Id: I726f18a344b2fe37f765a14684d1447c8b7ab00c Reviewed-by: Topi Reiniƶ --- src/corelib/tools/qtimezoneprivate_android.cpp | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'src/corelib/tools/qtimezoneprivate_android.cpp') diff --git a/src/corelib/tools/qtimezoneprivate_android.cpp b/src/corelib/tools/qtimezoneprivate_android.cpp index 6178fe935a..e66d00c67c 100644 --- a/src/corelib/tools/qtimezoneprivate_android.cpp +++ b/src/corelib/tools/qtimezoneprivate_android.cpp @@ -150,7 +150,7 @@ int QAndroidTimeZonePrivate::daylightTimeOffset(qint64 atMSecsSinceEpoch) const bool QAndroidTimeZonePrivate::hasDaylightTime() const { if ( androidTimeZone.isValid() ) - /* note: the Java function only tests for future daylight transtions, not past */ + /* note: the Java function only tests for future DST transtions, not past */ return androidTimeZone.callMethod("useDaylightTime" ); else return false; @@ -210,34 +210,34 @@ QTimeZonePrivate::Data QAndroidTimeZonePrivate::dataForLocalTime(qint64 forLocal } else { qint64 UTCepochMSecs; - // compare the UTC time with standard offset against normal daylight offset of one hour + // compare the UTC time with standard offset against normal DST offset of one hour qint64 standardUTCMSecs(forLocalMSecs - (standardTimeOffset(forLocalMSecs) * 1000)); qint64 daylightUTCMsecs; - // Check if daylight time does apply, - // checking also for daylight time boundaries + // Check if daylight-saving time applies, + // checking also for DST boundaries if (isDaylightTime(standardUTCMSecs)) { - // If daylight does apply, then standardUTCMSecs will be an hour or so ahead of the real epoch time + // If DST does apply, then standardUTCMSecs will be an hour or so ahead of the real epoch time // so check that time daylightUTCMsecs = standardUTCMSecs - daylightTimeOffset(standardUTCMSecs)*1000; if (isDaylightTime(daylightUTCMsecs)) { - // daylight time confirmed + // DST confirmed UTCepochMSecs = daylightUTCMsecs; } else { - // daylight time has just finished + // DST has just finished UTCepochMSecs = standardUTCMSecs; } } else { // Standard time indicated, but check for a false negative. - // Would a standard one-hour daylight offset indicate daylight time? + // Would a standard one-hour DST offset indicate DST? daylightUTCMsecs = standardUTCMSecs - 3600000; // 3600000 MSECS_PER_HOUR if (isDaylightTime(daylightUTCMsecs)) { - // daylight time may have just started, - // but double check against timezone's own daylight offset + // DST may have just started, + // but double check against timezone's own DST offset // (don't necessarily assume a one-hour offset) daylightUTCMsecs = standardUTCMSecs - daylightTimeOffset(daylightUTCMsecs)*1000; if (isDaylightTime(daylightUTCMsecs)) { - // daylight time confirmed + // DST confirmed UTCepochMSecs = daylightUTCMsecs; } else { // false positive, apply standard time after all -- cgit v1.2.3