Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Felix Münchhalfen
wine
Commits
331931a8
Commit
331931a8
authored
25 years ago
by
Eric Pouech
Committed by
Alexandre Julliard
25 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fixed play back of uncompressed AVI file.
Fixed exiting conditions.
parent
be625026
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
dlls/comctl32/animate.c
+41
-21
41 additions, 21 deletions
dlls/comctl32/animate.c
with
41 additions
and
21 deletions
dlls/comctl32/animate.c
+
41
−
21
View file @
331931a8
...
...
@@ -81,9 +81,32 @@ static BOOL ANIMATE_LoadFileA(ANIMATE_INFO *infoPtr, LPSTR lpName)
}
static
LRESULT
ANIMATE_DoStop
(
ANIMATE_INFO
*
infoPtr
)
{
EnterCriticalSection
(
&
infoPtr
->
cs
);
/* should stop playing */
if
(
infoPtr
->
hService
)
{
SERVICE_Delete
(
infoPtr
->
hService
);
infoPtr
->
hService
=
0
;
}
if
(
infoPtr
->
uTimer
)
{
KillTimer
(
infoPtr
->
hWnd
,
infoPtr
->
uTimer
);
infoPtr
->
uTimer
=
0
;
}
LeaveCriticalSection
(
&
infoPtr
->
cs
);
ANIMATE_Notify
(
infoPtr
,
ACN_STOP
);
return
TRUE
;
}
static
void
ANIMATE_Free
(
ANIMATE_INFO
*
infoPtr
)
{
if
(
infoPtr
->
hMMio
)
{
ANIMATE_DoStop
(
infoPtr
);
mmioClose
(
infoPtr
->
hMMio
,
0
);
if
(
infoPtr
->
hRes
)
{
FreeResource
(
infoPtr
->
hRes
);
...
...
@@ -117,31 +140,21 @@ static void ANIMATE_Free(ANIMATE_INFO *infoPtr)
}
static
LRESULT
ANIMATE_DoStop
(
ANIMATE_INFO
*
infoPtr
)
{
/* should stop playing */
if
(
infoPtr
->
hService
)
{
SERVICE_Delete
(
infoPtr
->
hService
);
infoPtr
->
hService
=
0
;
}
if
(
infoPtr
->
uTimer
)
{
KillTimer
(
infoPtr
->
hWnd
,
infoPtr
->
uTimer
);
infoPtr
->
uTimer
=
0
;
}
ANIMATE_Notify
(
infoPtr
,
ACN_STOP
);
return
TRUE
;
}
static
LRESULT
ANIMATE_PaintFrame
(
ANIMATE_INFO
*
infoPtr
,
HDC
hDC
)
{
if
(
hDC
)
{
if
(
!
hDC
||
!
infoPtr
->
inbih
)
return
TRUE
;
if
(
infoPtr
->
hic
)
StretchDIBits
(
hDC
,
0
,
0
,
infoPtr
->
outbih
->
biWidth
,
infoPtr
->
outbih
->
biHeight
,
0
,
0
,
infoPtr
->
outbih
->
biWidth
,
infoPtr
->
outbih
->
biHeight
,
infoPtr
->
outdata
,
(
LPBITMAPINFO
)
infoPtr
->
outbih
,
DIB_RGB_COLORS
,
SRCCOPY
);
}
else
StretchDIBits
(
hDC
,
0
,
0
,
infoPtr
->
inbih
->
biWidth
,
infoPtr
->
inbih
->
biHeight
,
0
,
0
,
infoPtr
->
inbih
->
biWidth
,
infoPtr
->
inbih
->
biHeight
,
infoPtr
->
indata
,
(
LPBITMAPINFO
)
infoPtr
->
inbih
,
DIB_RGB_COLORS
,
SRCCOPY
);
return
TRUE
;
}
...
...
@@ -156,7 +169,8 @@ static LRESULT ANIMATE_DrawFrame(ANIMATE_INFO* infoPtr)
mmioSeek
(
infoPtr
->
hMMio
,
infoPtr
->
lpIndex
[
infoPtr
->
currFrame
],
SEEK_SET
);
mmioRead
(
infoPtr
->
hMMio
,
infoPtr
->
indata
,
infoPtr
->
ash
.
dwSuggestedBufferSize
);
if
((
infoPtr
->
fnICDecompress
)(
infoPtr
->
hic
,
0
,
infoPtr
->
inbih
,
infoPtr
->
indata
,
if
(
infoPtr
->
hic
&&
(
infoPtr
->
fnICDecompress
)(
infoPtr
->
hic
,
0
,
infoPtr
->
inbih
,
infoPtr
->
indata
,
infoPtr
->
outbih
,
infoPtr
->
outdata
)
!=
ICERR_OK
)
{
LeaveCriticalSection
(
&
infoPtr
->
cs
);
WARN
(
"Decompression error
\n
"
);
...
...
@@ -407,6 +421,13 @@ static BOOL ANIMATE_GetAviCodec(ANIMATE_INFO *infoPtr)
{
DWORD
outSize
;
/* check uncompressed AVI */
if
(
infoPtr
->
ash
.
fccHandler
==
mmioFOURCC
(
'D'
,
'I'
,
'B'
,
' '
))
{
infoPtr
->
hic
=
0
;
return
TRUE
;
}
/* try to get a decompressor for that type */
infoPtr
->
hic
=
(
infoPtr
->
fnICOpen
)(
ICTYPE_VIDEO
,
infoPtr
->
ash
.
fccHandler
,
ICMODE_DECOMPRESS
);
...
...
@@ -529,7 +550,6 @@ static LRESULT ANIMATE_Stop(HWND hWnd, WPARAM wParam, LPARAM lParam)
}
static
LRESULT
ANIMATE_Create
(
HWND
hWnd
,
WPARAM
wParam
,
LPARAM
lParam
)
{
ANIMATE_INFO
*
infoPtr
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment