/////////////////////////////////////////////////////////////////////////////
-// Name: treectlg.cpp
+// Name: src/generic/treectlg.cpp
// Purpose: generic tree control implementation
// Author: Robert Roebling
// Created: 01/02/97
#if wxUSE_TREECTRL
-#include "wx/treebase.h"
#include "wx/treectrl.h"
+
+#ifndef WX_PRECOMP
+ #include "wx/dcclient.h"
+#endif
+
#include "wx/generic/treectlg.h"
#include "wx/timer.h"
#include "wx/textctrl.h"
#include "wx/imaglist.h"
#include "wx/settings.h"
-#include "wx/dcclient.h"
#include "wx/renderer.h"
if (IsExposed(exposed_x, exposed_y, 10000, h)) // 10000 = very much
{
- wxPen *pen =
+ const wxPen *pen =
#ifndef __WXMAC__
// don't draw rect outline if we already have the
// background color under Mac
rect.height = GetLineHeight(i);
// we have to return the logical coordinates, not physical ones
- int startX, startY;
- GetViewStart(& startX, & startY);
-
- rect.x -= startX*PIXELS_PER_UNIT;
- rect.y -= startY*PIXELS_PER_UNIT;
+ rect.SetTopLeft(CalcScrolledPosition(rect.GetTopLeft()));
return true;
}