git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@9368
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
- wxMimeTypesManager now can create file associations too
- wxCopyFile() respects the file permissions (Roland Scholz)
- wxFTP::GetFileSize() added (Søren Erland Vestø)
+- wxDateTime::IsSameDate() bug fixed
All (GUI):
- new wxToggleButton class (John Norris, Axel Schlueter)
+- wxCalendarCtrl now highlighting the date with time part bug fixed
wxMSW:
inline bool wxDateTime::IsSameDate(const wxDateTime& dt) const
{
- return (m_time - dt.m_time).Abs() < MILLISECONDS_PER_DAY;
+ Tm tm1 = GetTm(),
+ tm2 = dt.GetTm();
+
+ return tm1.year == tm2.year &&
+ tm1.mon == tm2.mon &&
+ tm1.mday == tm2.mday;
}
inline bool wxDateTime::IsSameTime(const wxDateTime& dt) const
if ( GetWindowStyle() & (wxRAISED_BORDER | wxSUNKEN_BORDER) )
{
// the border would clip the last line otherwise
- height += 4;
+ height += 6;
}
return wxSize(width, height);
wxCalendarDateAttr *attr = m_attrs[day - 1];
- bool isSel = m_date == date;
+ bool isSel = date.IsSameDate(m_date);
if ( isSel )
{
dc.SetTextForeground(m_colHighlightFg);