Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
a4fff714
Commit
a4fff714
authored
Jul 09, 2007
by
Evan Stade
Committed by
Alexandre Julliard
Jul 10, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdiplus: Updated draw_pie to use SaveDC/RestoreDC.
parent
685d7e79
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
graphics.c
dlls/gdiplus/graphics.c
+6
-5
No files found.
dlls/gdiplus/graphics.c
View file @
a4fff714
...
...
@@ -60,14 +60,16 @@ static void deg2xy(REAL angle, REAL x_0, REAL y_0, REAL *x, REAL *y)
static
GpStatus
draw_pie
(
GpGraphics
*
graphics
,
HBRUSH
gdibrush
,
HPEN
gdipen
,
REAL
x
,
REAL
y
,
REAL
width
,
REAL
height
,
REAL
startAngle
,
REAL
sweepAngle
)
{
HGDIOBJ
old_pen
,
old_brush
;
INT
save_state
;
REAL
x_0
,
y_0
,
x_1
,
y_1
,
x_2
,
y_2
;
if
(
!
graphics
)
return
InvalidParameter
;
old_pen
=
SelectObject
(
graphics
->
hdc
,
gdipen
);
old_brush
=
SelectObject
(
graphics
->
hdc
,
gdibrush
);
save_state
=
SaveDC
(
graphics
->
hdc
);
EndPath
(
graphics
->
hdc
);
SelectObject
(
graphics
->
hdc
,
gdipen
);
SelectObject
(
graphics
->
hdc
,
gdibrush
);
x_0
=
x
+
(
width
/
2
.
0
);
y_0
=
y
+
(
height
/
2
.
0
);
...
...
@@ -78,8 +80,7 @@ static GpStatus draw_pie(GpGraphics *graphics, HBRUSH gdibrush, HPEN gdipen,
Pie
(
graphics
->
hdc
,
roundr
(
x
),
roundr
(
y
),
roundr
(
x
+
width
),
roundr
(
y
+
height
),
roundr
(
x_1
),
roundr
(
y_1
),
roundr
(
x_2
),
roundr
(
y_2
));
SelectObject
(
graphics
->
hdc
,
old_pen
);
SelectObject
(
graphics
->
hdc
,
old_brush
);
RestoreDC
(
graphics
->
hdc
,
save_state
);
return
Ok
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment