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
8fbdd670
Commit
8fbdd670
authored
Aug 12, 2016
by
Vincent Povirk
Committed by
Alexandre Julliard
Aug 15, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdiplus/tests: Test mixing Begin/EndContainer and Save/Restore.
Signed-off-by:
Vincent Povirk
<
vincent@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
af500612
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
58 additions
and
0 deletions
+58
-0
graphics.c
dlls/gdiplus/tests/graphics.c
+58
-0
No files found.
dlls/gdiplus/tests/graphics.c
View file @
8fbdd670
...
...
@@ -326,6 +326,64 @@ static void test_save_restore(void)
log_state
(
state_a
,
&
state_log
);
/* A state created by SaveGraphics cannot be restored with EndContainer. */
GdipCreateFromHDC
(
hdc
,
&
graphics1
);
GdipSetInterpolationMode
(
graphics1
,
InterpolationModeBilinear
);
stat
=
GdipSaveGraphics
(
graphics1
,
&
state_a
);
expect
(
Ok
,
stat
);
GdipSetInterpolationMode
(
graphics1
,
InterpolationModeBicubic
);
stat
=
GdipEndContainer
(
graphics1
,
state_a
);
expect
(
Ok
,
stat
);
GdipGetInterpolationMode
(
graphics1
,
&
mode
);
todo_wine
expect
(
InterpolationModeBicubic
,
mode
);
stat
=
GdipRestoreGraphics
(
graphics1
,
state_a
);
expect
(
Ok
,
stat
);
GdipGetInterpolationMode
(
graphics1
,
&
mode
);
expect
(
InterpolationModeBilinear
,
mode
);
GdipDeleteGraphics
(
graphics1
);
log_state
(
state_a
,
&
state_log
);
/* A state created by BeginContainer cannot be restored with RestoreGraphics. */
GdipCreateFromHDC
(
hdc
,
&
graphics1
);
GdipSetInterpolationMode
(
graphics1
,
InterpolationModeBilinear
);
stat
=
GdipBeginContainer2
(
graphics1
,
&
state_a
);
expect
(
Ok
,
stat
);
GdipSetInterpolationMode
(
graphics1
,
InterpolationModeBicubic
);
stat
=
GdipRestoreGraphics
(
graphics1
,
state_a
);
expect
(
Ok
,
stat
);
GdipGetInterpolationMode
(
graphics1
,
&
mode
);
todo_wine
expect
(
InterpolationModeBicubic
,
mode
);
stat
=
GdipEndContainer
(
graphics1
,
state_a
);
expect
(
Ok
,
stat
);
GdipGetInterpolationMode
(
graphics1
,
&
mode
);
expect
(
InterpolationModeBilinear
,
mode
);
GdipDeleteGraphics
(
graphics1
);
log_state
(
state_a
,
&
state_log
);
/* BeginContainer and SaveGraphics use the same stack. */
GdipCreateFromHDC
(
hdc
,
&
graphics1
);
GdipSetInterpolationMode
(
graphics1
,
InterpolationModeBilinear
);
stat
=
GdipBeginContainer2
(
graphics1
,
&
state_a
);
expect
(
Ok
,
stat
);
GdipSetInterpolationMode
(
graphics1
,
InterpolationModeBicubic
);
stat
=
GdipSaveGraphics
(
graphics1
,
&
state_b
);
expect
(
Ok
,
stat
);
GdipSetInterpolationMode
(
graphics1
,
InterpolationModeNearestNeighbor
);
stat
=
GdipEndContainer
(
graphics1
,
state_a
);
expect
(
Ok
,
stat
);
GdipGetInterpolationMode
(
graphics1
,
&
mode
);
expect
(
InterpolationModeBilinear
,
mode
);
stat
=
GdipRestoreGraphics
(
graphics1
,
state_b
);
expect
(
Ok
,
stat
);
GdipGetInterpolationMode
(
graphics1
,
&
mode
);
expect
(
InterpolationModeBilinear
,
mode
);
GdipDeleteGraphics
(
graphics1
);
log_state
(
state_a
,
&
state_log
);
log_state
(
state_b
,
&
state_log
);
/* The same state value should never be returned twice. */
todo_wine
check_no_duplicates
(
state_log
);
...
...
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