Reduce the scope of some local variables
This commit is contained in:
@@ -792,13 +792,13 @@ static wxPointList wx_spline_point_list;
|
||||
void wx_quadratic_spline(double a1, double b1, double a2, double b2, double a3, double b3, double a4,
|
||||
double b4)
|
||||
{
|
||||
double xmid, ymid;
|
||||
double x1, y1, x2, y2, x3, y3, x4, y4;
|
||||
|
||||
wx_clear_stack();
|
||||
wx_spline_push(a1, b1, a2, b2, a3, b3, a4, b4);
|
||||
|
||||
while (wx_spline_pop(&x1, &y1, &x2, &y2, &x3, &y3, &x4, &y4)) {
|
||||
double xmid, ymid;
|
||||
xmid = (double)half(x2, x3);
|
||||
ymid = (double)half(y2, y3);
|
||||
if (fabs(x1 - xmid) < THRESHOLD && fabs(y1 - ymid) < THRESHOLD &&
|
||||
@@ -888,7 +888,7 @@ void wxDCImpl::DoDrawSpline( const wxPointList *points )
|
||||
wxCHECK_RET( IsOk(), wxT("invalid window dc") );
|
||||
|
||||
const wxPoint *p;
|
||||
double cx1, cy1, cx2, cy2, cx3, cy3, cx4, cy4;
|
||||
double cx1, cy1, cx2, cy2;
|
||||
double x1, y1, x2, y2;
|
||||
|
||||
wxPointList::compatibility_iterator node = points->GetFirst();
|
||||
@@ -919,6 +919,7 @@ void wxDCImpl::DoDrawSpline( const wxPointList *points )
|
||||
#endif // !wxUSE_STD_CONTAINERS
|
||||
)
|
||||
{
|
||||
double cx3, cy3, cx4, cy4;
|
||||
p = node->GetData();
|
||||
x1 = x2;
|
||||
y1 = y2;
|
||||
|
||||
Reference in New Issue
Block a user