Orb/Doxygen/qtools/qdatetime.cpp
changeset 4 468f4c8d3d5b
parent 0 42188c7ea2d9
equal deleted inserted replaced
3:d8fccb2cd802 4:468f4c8d3d5b
   489   Returns TRUE if the specified year \a y is a leap year.
   489   Returns TRUE if the specified year \a y is a leap year.
   490 */
   490 */
   491 
   491 
   492 bool QDate::leapYear( int y )
   492 bool QDate::leapYear( int y )
   493 {
   493 {
   494     return y % 4 == 0 && y % 100 != 0 || y % 400 == 0;
   494     return (y % 4 == 0 && y % 100 != 0) || (y % 400 == 0);
   495 }
   495 }
   496 
   496 
   497 /*!
   497 /*!
   498   \internal
   498   \internal
   499   Converts a Gregorian date to a Julian day.
   499   Converts a Gregorian date to a Julian day.