]> git.saurik.com Git - wxWidgets.git/commitdiff
made wxDateTimeDefault an object and not a reference to avoid (well, minimize) initia...
authorVadim Zeitlin <vadim@wxwidgets.org>
Fri, 15 Feb 2002 16:36:04 +0000 (16:36 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Fri, 15 Feb 2002 16:36:04 +0000 (16:36 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@14234 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/datetime.h
src/common/datetime.cpp

index 1dc31ef6d5495481c1742010868e9b82ab86eef3..ad0755da66c3c8823dee5c985ec6f1ddbfd58270 100644 (file)
@@ -115,7 +115,7 @@ class WXDLLEXPORT wxDateSpan;
 // wxInvalidDateTime)
 class WXDLLEXPORT wxDateTime;
 
-WXDLLEXPORT_DATA(extern const wxDateTime&) wxDefaultDateTime;
+WXDLLEXPORT_DATA(extern const wxDateTime) wxDefaultDateTime;
 #define wxInvalidDateTime wxDefaultDateTime
 
 // ----------------------------------------------------------------------------
index 7dc31201942b12699377b48881284bbecb86462c..418a72f51c89faad35ac925dcfc6396774254732 100644 (file)
@@ -211,10 +211,7 @@ static const wxDateTime::wxDateTime_t gs_cumulatedDays[2][MONTHS_IN_YEAR] =
 
 // in the fine tradition of ANSI C we use our equivalent of (time_t)-1 to
 // indicate an invalid wxDateTime object
-
-static const wxDateTime gs_dtDefault;
-
-const wxDateTime& wxDefaultDateTime = gs_dtDefault;
+const wxDateTime wxDefaultDateTime;
 
 wxDateTime::Country wxDateTime::ms_country = wxDateTime::Country_Unknown;