]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/time.cpp
Added Property List classes to main library; added proplist sample; merged
[wxWidgets.git] / src / common / time.cpp
index 01eed9a49520a61ed72303d133aa385ad2bde37d..c8a19d63956aab43eedf9b606f14edb1c8b5a914 100644 (file)
@@ -27,20 +27,24 @@ seconds since January 1, 1901, GMT.
 
 #include "wx/setup.h"
 
-#if USE_TIMEDATE
+#if wxUSE_TIMEDATE
 
 #include "wx/time.h"
 #include "wx/date.h"
 #include "wx/utils.h"
 #include <wx/intl.h>
 
-#if USE_IOSTREAMH
+#if wxUSE_IOSTREAMH
 #include <iostream.h>
+#include <iomanip.h>
 #else
 #include <iostream>
+#include <iomanip>
+#  ifdef _MSC_VER
+      using namespace std;
+#  endif
 #endif
 
-#include <iomanip.h>
 #include <string.h>
 
 #if !USE_SHARED_LIBRARY
@@ -267,6 +271,38 @@ secondTy wxTime::GetSecond() const
                  return (secondTy)(((sec % 86400) % 3600) % 60);
 }
 
+secondTy wxTime::GetSecondGMT() const
+/*
+        Return the minute of this wxTime in GMT.
+*/
+{
+        return (secondTy)(((sec % 86400) % 3600) % 60);
+}
+
+int wxTime::GetDay() const
+{
+    wxDate da((wxDate) *this);
+    return da.GetDay();
+}
+
+int wxTime::GetDayOfWeek() const
+{
+    wxDate da((wxDate) *this);
+    return da.GetDayOfWeek();
+}
+
+int wxTime::GetMonth() const
+{
+    wxDate da((wxDate) *this);
+    return da.GetMonth();
+}
+
+int wxTime::GetYear() const
+{
+    wxDate da((wxDate) *this);
+    return da.GetYear();
+}
+
 wxTime wxTime::Max(const wxTime& t) const
 {
         if (t < *this) return *this;