use int instead of size_t for a couple member variables

it's simpler, and there is no point in using size_t anyway since they are assigned from ints

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69815 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Paul Cornett 2011-11-25 00:52:24 +00:00
parent 6cdab3b498
commit 46a1983ae4
2 changed files with 7 additions and 11 deletions

View File

@ -122,13 +122,11 @@ private:
void Init();
void CreateRects( const wxRegion& r );
size_t m_current;
wxRegion m_region;
wxRect *m_rects;
size_t m_numRects;
int m_numRects;
int m_current;
private:
DECLARE_DYNAMIC_CLASS(wxRegionIterator)
};

View File

@ -370,15 +370,13 @@ void wxRegionIterator::CreateRects( const wxRegion& region )
if (!gdkregion)
return;
GdkRectangle *gdkrects = NULL;
gint numRects = 0;
gdk_region_get_rectangles( gdkregion, &gdkrects, &numRects );
GdkRectangle* gdkrects;
gdk_region_get_rectangles(gdkregion, &gdkrects, &m_numRects);
m_numRects = numRects;
if (numRects)
if (m_numRects)
{
m_rects = new wxRect[m_numRects];
for (size_t i=0; i < m_numRects; ++i)
for (int i = 0; i < m_numRects; ++i)
{
GdkRectangle &gr = gdkrects[i];
wxRect &wr = m_rects[i];
@ -467,7 +465,7 @@ wxRegionIterator& wxRegionIterator::operator=(const wxRegionIterator& ri)
if ( m_numRects )
{
m_rects = new wxRect[m_numRects];
for ( unsigned int n = 0; n < m_numRects; n++ )
for ( int n = 0; n < m_numRects; n++ )
m_rects[n] = ri.m_rects[n];
}
else