diff options
| author | ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> | 2022-03-21 15:56:50 +0100 |
|---|---|---|
| committer | ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> | 2022-03-21 15:56:50 +0100 |
| commit | d87b62ea6924c80127ce82b01ad91ea80ace5d73 (patch) | |
| tree | 61e56c8484ffeaa8965f256fa59fa41565665b78 /src/drivers/Xlib/Fl_Xlib_Graphics_Driver_vertex.cxx | |
| parent | bf5b902180f0e5654f5802cf9ef588ecf57d20c6 (diff) | |
Avoid using same name (p) for distinct members of derived classes.
Diffstat (limited to 'src/drivers/Xlib/Fl_Xlib_Graphics_Driver_vertex.cxx')
| -rw-r--r-- | src/drivers/Xlib/Fl_Xlib_Graphics_Driver_vertex.cxx | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_vertex.cxx b/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_vertex.cxx index 59b3e58eb..3b43a360a 100644 --- a/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_vertex.cxx +++ b/src/drivers/Xlib/Fl_Xlib_Graphics_Driver_vertex.cxx @@ -1,7 +1,7 @@ // // Portable drawing routines for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2018 by Bill Spitzak and others. +// Copyright 1998-2022 by Bill Spitzak and others. // // This library is free software. Distribution and use rights are outlined in // the file "COPYING" which should have been included with this file. If this @@ -29,7 +29,7 @@ void Fl_Xlib_Graphics_Driver::end_points() { - if (n>1) XDrawPoints(fl_display, fl_window, gc_, (XPoint*)p, n, 0); + if (n>1) XDrawPoints(fl_display, fl_window, gc_, short_point, n, 0); } void Fl_Xlib_Graphics_Driver::end_line() { @@ -37,13 +37,13 @@ void Fl_Xlib_Graphics_Driver::end_line() { end_points(); return; } - if (n>1) XDrawLines(fl_display, fl_window, gc_, (XPoint*)p, n, 0); + if (n>1) XDrawLines(fl_display, fl_window, gc_, short_point, n, 0); } void Fl_Xlib_Graphics_Driver::end_loop() { fixloop(); if (n>2) { - transformed_vertex0(p[0].x , p[0].y ); + transformed_vertex0(short_point[0].x , short_point[0].y ); } end_line(); } @@ -54,13 +54,13 @@ void Fl_Xlib_Graphics_Driver::end_polygon() { end_line(); return; } - if (n>2) XFillPolygon(fl_display, fl_window, gc_, (XPoint*)p, n, Convex, 0); + if (n>2) XFillPolygon(fl_display, fl_window, gc_, short_point, n, Convex, 0); } void Fl_Xlib_Graphics_Driver::gap() { - while (n>gap_+2 && p[n-1].x == p[gap_].x && p[n-1].y == p[gap_].y) n--; + while (n>gap_+2 && short_point[n-1].x == short_point[gap_].x && short_point[n-1].y == short_point[gap_].y) n--; if (n > gap_+2) { - transformed_vertex0(p[gap_].x, p[gap_].y); + transformed_vertex0(short_point[gap_].x, short_point[gap_].y); gap_ = n; } else { n = gap_; @@ -73,7 +73,7 @@ void Fl_Xlib_Graphics_Driver::end_complex_polygon() { end_line(); return; } - if (n>2) XFillPolygon(fl_display, fl_window, gc_, (XPoint*)p, n, 0, 0); + if (n>2) XFillPolygon(fl_display, fl_window, gc_, short_point, n, 0, 0); } // shortcut the closed circles so they use XDrawArc: |
