compilation fixes for wxUSE_DATETIME==0 (another part of patch 1203970)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37493 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -411,7 +411,11 @@ bool wxXmlResource::UpdateResources()
|
||||
{
|
||||
# if wxUSE_FILESYSTEM
|
||||
file = fsys.OpenFile(m_data[i].File);
|
||||
# if wxUSE_DATETIME
|
||||
modif = file && file->GetModificationTime() > m_data[i].Time;
|
||||
# else // wxUSE_DATETIME
|
||||
modif = true;
|
||||
# endif // wxUSE_DATETIME
|
||||
if (!file)
|
||||
{
|
||||
wxLogError(_("Cannot open file '%s'."), m_data[i].File.c_str());
|
||||
@@ -419,9 +423,13 @@ bool wxXmlResource::UpdateResources()
|
||||
}
|
||||
wxDELETE(file);
|
||||
wxUnusedVar(file);
|
||||
# else
|
||||
# else // wxUSE_FILESYSTEM
|
||||
# if wxUSE_DATETIME
|
||||
modif = wxDateTime(wxFileModificationTime(m_data[i].File)) > m_data[i].Time;
|
||||
# endif
|
||||
# else // wxUSE_DATETIME
|
||||
modif = true;
|
||||
# endif // wxUSE_DATETIME
|
||||
# endif // wxUSE_FILESYSTEM
|
||||
}
|
||||
|
||||
if (modif)
|
||||
@@ -477,11 +485,13 @@ bool wxXmlResource::UpdateResources()
|
||||
}
|
||||
|
||||
ProcessPlatformProperty(m_data[i].Doc->GetRoot());
|
||||
#if wxUSE_DATETIME
|
||||
#if wxUSE_FILESYSTEM
|
||||
m_data[i].Time = file->GetModificationTime();
|
||||
#else
|
||||
#else // wxUSE_FILESYSTEM
|
||||
m_data[i].Time = wxDateTime(wxFileModificationTime(m_data[i].File));
|
||||
#endif
|
||||
#endif // wxUSE_FILESYSTEM
|
||||
#endif // wxUSE_DATETIME
|
||||
}
|
||||
|
||||
# if wxUSE_FILESYSTEM
|
||||
|
Reference in New Issue
Block a user