TRUE and FALSE, not true and false.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12305 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -376,7 +376,7 @@ void wxCalendarCtrl::EnableMonthChange(bool enable)
|
||||
|
||||
bool wxCalendarCtrl::SetDate(const wxDateTime& date)
|
||||
{
|
||||
bool retval = false;
|
||||
bool retval = FALSE;
|
||||
|
||||
bool sameMonth = m_date.GetMonth() == date.GetMonth(),
|
||||
sameYear = m_date.GetYear() == date.GetYear();
|
||||
@@ -386,7 +386,7 @@ bool wxCalendarCtrl::SetDate(const wxDateTime& date)
|
||||
if ( sameMonth && sameYear )
|
||||
{
|
||||
// just change the day
|
||||
retval = true;
|
||||
retval = TRUE;
|
||||
ChangeDay(date);
|
||||
}
|
||||
else
|
||||
@@ -398,7 +398,7 @@ bool wxCalendarCtrl::SetDate(const wxDateTime& date)
|
||||
}
|
||||
|
||||
// change everything
|
||||
retval = true;
|
||||
retval = TRUE;
|
||||
m_date = date;
|
||||
|
||||
if ( !(GetWindowStyle() & wxCAL_SEQUENTIAL_MONTH_SELECTION) )
|
||||
@@ -469,15 +469,15 @@ void wxCalendarCtrl::SetDateAndNotify(const wxDateTime& date)
|
||||
|
||||
bool wxCalendarCtrl::SetLowerDateLimit(const wxDateTime& date /* = wxDefaultDateTime */)
|
||||
{
|
||||
bool retval = true;
|
||||
bool retval = TRUE;
|
||||
|
||||
if ( !(date.IsValid()) || ( ( m_highdate.IsValid() ) ? ( date <= m_highdate ) : true ) )
|
||||
if ( !(date.IsValid()) || ( ( m_highdate.IsValid() ) ? ( date <= m_highdate ) : TRUE ) )
|
||||
{
|
||||
m_lowdate = date;
|
||||
}
|
||||
else
|
||||
{
|
||||
retval = false;
|
||||
retval = FALSE;
|
||||
}
|
||||
|
||||
return retval;
|
||||
@@ -485,15 +485,15 @@ bool wxCalendarCtrl::SetLowerDateLimit(const wxDateTime& date /* = wxDefaultDate
|
||||
|
||||
bool wxCalendarCtrl::SetUpperDateLimit(const wxDateTime& date /* = wxDefaultDateTime */)
|
||||
{
|
||||
bool retval = true;
|
||||
bool retval = TRUE;
|
||||
|
||||
if ( !(date.IsValid()) || ( ( m_lowdate.IsValid() ) ? ( date >= m_lowdate ) : true ) )
|
||||
if ( !(date.IsValid()) || ( ( m_lowdate.IsValid() ) ? ( date >= m_lowdate ) : TRUE ) )
|
||||
{
|
||||
m_highdate = date;
|
||||
}
|
||||
else
|
||||
{
|
||||
retval = false;
|
||||
retval = FALSE;
|
||||
}
|
||||
|
||||
return retval;
|
||||
@@ -501,18 +501,18 @@ bool wxCalendarCtrl::SetUpperDateLimit(const wxDateTime& date /* = wxDefaultDate
|
||||
|
||||
bool wxCalendarCtrl::SetDateRange(const wxDateTime& lowerdate /* = wxDefaultDateTime */, const wxDateTime& upperdate /* = wxDefaultDateTime */)
|
||||
{
|
||||
bool retval = true;
|
||||
bool retval = TRUE;
|
||||
|
||||
if (
|
||||
( !( lowerdate.IsValid() ) || ( ( upperdate.IsValid() ) ? ( lowerdate <= upperdate ) : true ) ) &&
|
||||
( !( upperdate.IsValid() ) || ( ( lowerdate.IsValid() ) ? ( upperdate >= lowerdate ) : true ) ) )
|
||||
( !( lowerdate.IsValid() ) || ( ( upperdate.IsValid() ) ? ( lowerdate <= upperdate ) : TRUE ) ) &&
|
||||
( !( upperdate.IsValid() ) || ( ( lowerdate.IsValid() ) ? ( upperdate >= lowerdate ) : TRUE ) ) )
|
||||
{
|
||||
m_lowdate = lowerdate;
|
||||
m_highdate = upperdate;
|
||||
}
|
||||
else
|
||||
{
|
||||
retval = false;
|
||||
retval = FALSE;
|
||||
}
|
||||
|
||||
return retval;
|
||||
@@ -558,16 +558,16 @@ bool wxCalendarCtrl::IsDateShown(const wxDateTime& date) const
|
||||
|
||||
bool wxCalendarCtrl::IsDateInRange(const wxDateTime& date) const
|
||||
{
|
||||
bool retval = true;
|
||||
bool retval = TRUE;
|
||||
// Check if the given date is in the range specified
|
||||
retval = ( ( ( m_lowdate.IsValid() ) ? ( date >= m_lowdate ) : true )
|
||||
&& ( ( m_highdate.IsValid() ) ? ( date <= m_highdate ) : true ) );
|
||||
retval = ( ( ( m_lowdate.IsValid() ) ? ( date >= m_lowdate ) : TRUE )
|
||||
&& ( ( m_highdate.IsValid() ) ? ( date <= m_highdate ) : TRUE ) );
|
||||
return retval;
|
||||
}
|
||||
|
||||
bool wxCalendarCtrl::ChangeYear(wxDateTime* target) const
|
||||
{
|
||||
bool retval = false;
|
||||
bool retval = FALSE;
|
||||
|
||||
if ( !(IsDateInRange(*target)) )
|
||||
{
|
||||
@@ -576,7 +576,7 @@ bool wxCalendarCtrl::ChangeYear(wxDateTime* target) const
|
||||
if ( target->GetYear() >= GetLowerDateLimit().GetYear() )
|
||||
{
|
||||
*target = GetLowerDateLimit();
|
||||
retval = true;
|
||||
retval = TRUE;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -588,7 +588,7 @@ bool wxCalendarCtrl::ChangeYear(wxDateTime* target) const
|
||||
if ( target->GetYear() <= GetUpperDateLimit().GetYear() )
|
||||
{
|
||||
*target = GetUpperDateLimit();
|
||||
retval = true;
|
||||
retval = TRUE;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -598,7 +598,7 @@ bool wxCalendarCtrl::ChangeYear(wxDateTime* target) const
|
||||
}
|
||||
else
|
||||
{
|
||||
retval = true;
|
||||
retval = TRUE;
|
||||
}
|
||||
|
||||
return retval;
|
||||
@@ -606,11 +606,11 @@ bool wxCalendarCtrl::ChangeYear(wxDateTime* target) const
|
||||
|
||||
bool wxCalendarCtrl::ChangeMonth(wxDateTime* target) const
|
||||
{
|
||||
bool retval = true;
|
||||
bool retval = TRUE;
|
||||
|
||||
if ( !(IsDateInRange(*target)) )
|
||||
{
|
||||
retval = false;
|
||||
retval = FALSE;
|
||||
|
||||
if ( target->GetMonth() < m_date.GetMonth() )
|
||||
{
|
||||
@@ -858,7 +858,7 @@ void wxCalendarCtrl::OnPaint(wxPaintEvent& WXUNUSED(event))
|
||||
{
|
||||
wxDateTime ldpm = wxDateTime(1,m_date.GetMonth(), m_date.GetYear()) - wxDateSpan::Day(); // last day prev month
|
||||
// Check if range permits change
|
||||
if ( IsDateInRange(ldpm) && ( ( ldpm.GetYear() == m_date.GetYear() ) ? true : AllowYearChange() ) )
|
||||
if ( IsDateInRange(ldpm) && ( ( ldpm.GetYear() == m_date.GetYear() ) ? TRUE : AllowYearChange() ) )
|
||||
{
|
||||
m_leftArrowRect = wxRect(larrowx - 3, arrowy - 3, (arrowheight / 2) + 8, (arrowheight + 6));
|
||||
dc.SetBrush(wxBrush(*wxBLACK, wxSOLID));
|
||||
@@ -868,7 +868,7 @@ void wxCalendarCtrl::OnPaint(wxPaintEvent& WXUNUSED(event))
|
||||
dc.DrawRectangle(m_leftArrowRect);
|
||||
}
|
||||
wxDateTime fdnm = wxDateTime(1,m_date.GetMonth(), m_date.GetYear()) + wxDateSpan::Month(); // first day next month
|
||||
if ( IsDateInRange(fdnm) && ( ( fdnm.GetYear() == m_date.GetYear() ) ? true : AllowYearChange() ) )
|
||||
if ( IsDateInRange(fdnm) && ( ( fdnm.GetYear() == m_date.GetYear() ) ? TRUE : AllowYearChange() ) )
|
||||
{
|
||||
m_rightArrowRect = wxRect(rarrowx - 4, arrowy - 3, (arrowheight / 2) + 8, (arrowheight + 6));
|
||||
dc.SetBrush(wxBrush(*wxBLACK, wxSOLID));
|
||||
@@ -952,7 +952,7 @@ void wxCalendarCtrl::OnPaint(wxPaintEvent& WXUNUSED(event))
|
||||
bool changedColours = FALSE,
|
||||
changedFont = FALSE;
|
||||
|
||||
bool isSel = false;
|
||||
bool isSel = FALSE;
|
||||
wxCalendarDateAttr *attr = NULL;
|
||||
|
||||
if ( date.GetMonth() != m_date.GetMonth() || !IsDateInRange(date) )
|
||||
@@ -1218,7 +1218,7 @@ void wxCalendarCtrl::HighlightRange(wxPaintDC* pDC, const wxDateTime& fromdate,
|
||||
|
||||
bool wxCalendarCtrl::GetDateCoord(const wxDateTime& date, int *day, int *week) const
|
||||
{
|
||||
bool retval = true;
|
||||
bool retval = TRUE;
|
||||
|
||||
#if DEBUG_PAINT
|
||||
wxLogDebug("+++ GetDateCoord: (%s) +++", date.Format("%d %m %Y"));
|
||||
@@ -1295,7 +1295,7 @@ bool wxCalendarCtrl::GetDateCoord(const wxDateTime& date, int *day, int *week) c
|
||||
{
|
||||
*day = -1;
|
||||
*week = -1;
|
||||
retval = false;
|
||||
retval = FALSE;
|
||||
}
|
||||
|
||||
#if DEBUG_PAINT
|
||||
|
@@ -5454,7 +5454,7 @@ int wxGrid::SendEvent( const wxEventType type,
|
||||
wxMouseEvent& mouseEv )
|
||||
{
|
||||
bool claimed;
|
||||
bool vetoed= false;
|
||||
bool vetoed= FALSE;
|
||||
|
||||
if ( type == wxEVT_GRID_ROW_SIZE || type == wxEVT_GRID_COL_SIZE )
|
||||
{
|
||||
@@ -5525,7 +5525,7 @@ int wxGrid::SendEvent( const wxEventType type,
|
||||
int row, int col )
|
||||
{
|
||||
bool claimed;
|
||||
bool vetoed= false;
|
||||
bool vetoed= FALSE;
|
||||
|
||||
if ( type == wxEVT_GRID_ROW_SIZE || type == wxEVT_GRID_COL_SIZE )
|
||||
{
|
||||
|
Reference in New Issue
Block a user