diff options
author | Sven Weidauer <sven.weidauer@gmail.com> | 2011-01-31 07:57:52 +0000 |
---|---|---|
committer | Sven Weidauer <sven.weidauer@gmail.com> | 2011-01-31 07:57:52 +0000 |
commit | fd23621211e814d86da1a12bf0f5a20368d4c037 (patch) | |
tree | f84c9dff108c49034c86dbdfd8d8b428d6ab4fb3 /cocoa/plotter.m | |
parent | b1662d0b09963c0d86b417f6acb2ce4c6b9a15dd (diff) | |
download | netsurf-fd23621211e814d86da1a12bf0f5a20368d4c037.tar.gz netsurf-fd23621211e814d86da1a12bf0f5a20368d4c037.tar.bz2 |
Changing Xcode project file to build using the Makefiles and fixed some warnings.
svn path=/trunk/netsurf/; revision=11558
Diffstat (limited to 'cocoa/plotter.m')
-rw-r--r-- | cocoa/plotter.m | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/cocoa/plotter.m b/cocoa/plotter.m index bff1ac02a..2d5e814f0 100644 --- a/cocoa/plotter.m +++ b/cocoa/plotter.m @@ -29,7 +29,7 @@ static void cocoa_plot_render_path(NSBezierPath *path,const plot_style_t *pstyle); static void cocoa_plot_path_set_stroke_pattern(NSBezierPath *path,const plot_style_t *pstyle); -static void inline cocoa_center_pixel( bool x, bool y ); +static inline void cocoa_center_pixel( bool x, bool y ); static NSRect cocoa_plot_clip_rect; @@ -208,13 +208,17 @@ static bool plot_path(const float *p, unsigned int n, colour fill, float width, while (n--) { switch ((int)*p++) { - case PLOTTER_PATH_MOVE: - [path moveToPoint: NEXT_POINT()]; + case PLOTTER_PATH_MOVE: { + const NSPoint pt = NEXT_POINT(); + [path moveToPoint: pt]; break; + } - case PLOTTER_PATH_LINE: - [path lineToPoint: NEXT_POINT()]; + case PLOTTER_PATH_LINE: { + const NSPoint pt = NEXT_POINT(); + [path lineToPoint: pt]; break; + } case PLOTTER_PATH_BEZIER: { const NSPoint cp1 = NEXT_POINT(); |