[prev in list] [next in list] [prev in thread] [next in thread]
List: wine-cvs
Subject: Huw Davies : gdi32: Pass the path directly to start_new_stroke().
From: Alexandre Julliard <julliard () winehq ! org>
Date: 2016-07-29 15:17:09
Message-ID: E1bT9XB-0001DW-DD () winehq ! org
[Download RAW message or body]
Module: wine
Branch: master
Commit: 1b4f0f8a07c81363aa4946de382e1852675cbec6
URL: http://source.winehq.org/git/wine.git/?a=commit;h=1b4f0f8a07c81363aa4946de382e1852675cbec6
Author: Huw Davies <huw@codeweavers.com>
Date: Fri Jul 29 15:09:27 2016 +0100
gdi32: Pass the path directly to start_new_stroke().
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
---
dlls/gdi32/path.c | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/dlls/gdi32/path.c b/dlls/gdi32/path.c
index c03208f..a5d01bc 100644
--- a/dlls/gdi32/path.c
+++ b/dlls/gdi32/path.c
@@ -298,10 +298,8 @@ static void reverse_points( POINT *points, UINT count )
}
/* start a new path stroke if necessary */
-static BOOL start_new_stroke( struct path_physdev *physdev )
+static BOOL start_new_stroke( struct gdi_path *path )
{
- struct gdi_path *path = physdev->path;
-
if (!path->newStroke && path->count &&
!(path->flags[path->count - 1] & PT_CLOSEFIGURE) &&
path->points[path->count - 1].x == path->pos.x &&
@@ -309,7 +307,7 @@ static BOOL start_new_stroke( struct path_physdev *physdev )
return TRUE;
path->newStroke = FALSE;
- return add_points( physdev->path, &path->pos, 1, PT_MOVETO ) != NULL;
+ return add_points( path, &path->pos, 1, PT_MOVETO ) != NULL;
}
/* set current position to the last point that was added to the path */
@@ -330,7 +328,7 @@ static void close_figure( struct gdi_path *path )
static BOOL add_log_points_new_stroke( struct path_physdev *physdev, const POINT *points,
DWORD count, BYTE type )
{
- if (!start_new_stroke( physdev )) return FALSE;
+ if (!start_new_stroke( physdev->path )) return FALSE;
if (!add_log_points( physdev, points, count, type )) return FALSE;
update_current_pos( physdev->path );
return TRUE;
@@ -1143,7 +1141,7 @@ static BOOL PATH_Arc( PHYSDEV dev, INT x1, INT y1, INT x2, INT y2,
}
/* arcto: Add a PT_MOVETO only if this is the first entry in a stroke */
- if (lines==-1 && !start_new_stroke( physdev )) return FALSE;
+ if (lines == -1 && !start_new_stroke( physdev->path )) return FALSE;
/* Add the arc to the path with one Bezier spline per quadrant that the
* arc spans */
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic