summaryrefslogtreecommitdiffstats
path: root/src/corelib/tools/qdatetime.cpp
diff options
context:
space:
mode:
authorXizhi Zhu <xizhi.zhu@gmail.com>2012-01-06 17:53:38 +0200
committerQt by Nokia <qt-info@nokia.com>2012-01-09 07:46:08 +0100
commit84bd87353a3f092d00942e90aa20be3668a7456b (patch)
tree20ad02e110e0a7c34e28aff9545a6dd8d3229f0c /src/corelib/tools/qdatetime.cpp
parent7aeccb183a827e8504d7dd8614d1ca555caf61d9 (diff)
Clean-up the interface for QDate.
Four overload functions removed while keeping source compatibility: - shortMonthName() - shortDayName() - longMonthName() - longDayName() Two functions removed since they have confusing names: - gregorianToJulian() - julianToGregorian() Change-Id: Iaaea066a3fb77b1ee3499d3049fcec5563054cdf Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Reviewed-by: John Layt <jlayt@kde.org>
Diffstat (limited to 'src/corelib/tools/qdatetime.cpp')
-rw-r--r--src/corelib/tools/qdatetime.cpp81
1 files changed, 0 insertions, 81 deletions
diff --git a/src/corelib/tools/qdatetime.cpp b/src/corelib/tools/qdatetime.cpp
index 8a452847f1..d20b07589e 100644
--- a/src/corelib/tools/qdatetime.cpp
+++ b/src/corelib/tools/qdatetime.cpp
@@ -566,18 +566,6 @@ QString QDate::shortMonthName(int month, QDate::MonthNameType type)
}
/*!
- Returns the short version of the name of the \a month. The
- returned name is in normal type which can be used for date formatting.
-
- \sa toString(), longMonthName(), shortDayName(), longDayName()
- */
-
-QString QDate::shortMonthName(int month)
-{
- return shortMonthName(month, QDate::DateFormat);
-}
-
-/*!
\since 4.5
Returns the long name of the \a month for the representation specified
@@ -623,21 +611,6 @@ QString QDate::longMonthName(int month, MonthNameType type)
}
/*!
- Returns the long version of the name of the \a month. The
- returned name is in normal type which can be used for date formatting.
-
- \sa toString(), shortMonthName(), shortDayName(), longDayName()
- */
-
-QString QDate::longMonthName(int month)
-{
- if (month < 1 || month > 12) {
- month = 1;
- }
- return QLocale::system().monthName(month, QLocale::LongFormat);
-}
-
-/*!
\since 4.5
Returns the short name of the \a weekday for the representation specified
@@ -678,21 +651,6 @@ QString QDate::shortDayName(int weekday, MonthNameType type)
}
/*!
- Returns the short version of the name of the \a weekday. The
- returned name is in normal type which can be used for date formatting.
-
- \sa toString(), longDayName(), shortMonthName(), longMonthName()
- */
-
-QString QDate::shortDayName(int weekday)
-{
- if (weekday < 1 || weekday > 7) {
- weekday = 1;
- }
- return QLocale::system().dayName(weekday, QLocale::ShortFormat);
-}
-
-/*!
\since 4.5
Returns the long name of the \a weekday for the representation specified
@@ -731,21 +689,6 @@ QString QDate::longDayName(int weekday, MonthNameType type)
}
return QLocale::system().dayName(weekday, QLocale::LongFormat);
}
-
-/*!
- Returns the long version of the name of the \a weekday. The
- returned name is in normal type which can be used for date formatting.
-
- \sa toString(), shortDayName(), shortMonthName(), longMonthName()
- */
-
-QString QDate::longDayName(int weekday)
-{
- if (weekday < 1 || weekday > 7) {
- weekday = 1;
- }
- return QLocale::system().dayName(weekday, QLocale::LongFormat);
-}
#endif //QT_NO_TEXTDATE
#ifndef QT_NO_DATESTRING
@@ -1346,30 +1289,6 @@ bool QDate::isLeapYear(int y)
}
}
-/*!
- \internal
-
- This function has a confusing name and shouldn't be part of the
- API anyway, since we have toJulian() and fromJulian().
- ### Qt 5: remove it
-*/
-uint QDate::gregorianToJulian(int y, int m, int d)
-{
- return julianDayFromDate(y, m, d);
-}
-
-/*!
- \internal
-
- This function has a confusing name and shouldn't be part of the
- API anyway, since we have toJulian() and fromJulian().
- ### Qt 5: remove it
-*/
-void QDate::julianToGregorian(uint jd, int &y, int &m, int &d)
-{
- getDateFromJulianDay(jd, &y, &m, &d);
-}
-
/*! \fn static QDate QDate::fromJulianDay(int jd)
Converts the Julian day \a jd to a QDate.