]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/datetime.h
Added missing AddBook
[wxWidgets.git] / include / wx / datetime.h
index 017c226b8925a8f15cd3958364fed60adc668c92..c546534b8152471624e9954a6c3e6ad37de43fc6 100644 (file)
 #ifndef _WX_DATETIME_H
 #define _WX_DATETIME_H
 
-#ifdef __GNUG__
+#if defined(__GNUG__) && !defined(__APPLE__)
     #pragma interface "datetime.h"
 #endif
 
+#include "wx/defs.h"
+
 #if wxUSE_DATETIME
 
 #include <time.h>
@@ -657,8 +659,10 @@ public:
     // ------------------------------------------------------------------------
 
         // set to the given week day in the same week as this one
-    wxDateTime& SetToWeekDayInSameWeek(WeekDay weekday);
-    inline wxDateTime GetWeekDayInSameWeek(WeekDay weekday) const;
+    wxDateTime& SetToWeekDayInSameWeek(WeekDay weekday,
+                                       WeekFlags flags = Monday_First);
+    inline wxDateTime GetWeekDayInSameWeek(WeekDay weekday,
+                                           WeekFlags flags = Monday_First) const;
 
         // set to the next week day following this one
     wxDateTime& SetToNextWeekDay(WeekDay weekday);
@@ -692,8 +696,12 @@ public:
         // sets the date to the given day of the given week in the year,
         // returns TRUE on success and FALSE if given date doesn't exist (e.g.
         // numWeek is > 53)
-    bool SetToTheWeek(wxDateTime_t numWeek, WeekDay weekday = Mon);
-    inline wxDateTime GetWeek(wxDateTime_t numWeek, WeekDay weekday = Mon) const;
+    bool SetToTheWeek(wxDateTime_t numWeek,
+                      WeekDay weekday = Mon,
+                      WeekFlags flags = Monday_First);
+    inline wxDateTime GetWeek(wxDateTime_t numWeek,
+                              WeekDay weekday = Mon,
+                              WeekFlags flags = Monday_First) const;
 
         // sets the date to the last day of the given (or current) month or the
         // given (or current) year
@@ -843,6 +851,15 @@ public:
         //     adoption of the Gregorian calendar is simply unknown.
     bool IsGregorianDate(GregorianAdoption country = Gr_Standard) const;
 
+    // dos date and time format
+    // ------------------------------------------------------------------------
+
+        // set from the DOS packed format
+    wxDateTime& SetFromDOS(unsigned long ddt);
+
+        // pack the date in DOS format
+    unsigned long GetAsDOS() const;
+
     // comparison (see also functions below for operator versions)
     // ------------------------------------------------------------------------