Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
b44af64d
Commit
b44af64d
authored
Aug 16, 2000
by
Niclas Karlsson MATE
Committed by
Alexandre Julliard
Aug 16, 2000
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Implemented ACS_CENTER for animation controls.
parent
a257ba24
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
3 deletions
+22
-3
animate.c
dlls/comctl32/animate.c
+22
-3
No files found.
dlls/comctl32/animate.c
View file @
b44af64d
...
...
@@ -11,7 +11,7 @@
*
* TODO:
* - check for the 'rec ' list in some AVI files
* - implement some missing flags (ACS_TRANSPARENT
and ACS_CENTER
)
* - implement some missing flags (ACS_TRANSPARENT)
* - protection between service thread and wndproc messages handling
* concurrent access to infoPtr
*/
...
...
@@ -613,6 +613,23 @@ static BOOL ANIMATE_GetAviCodec(ANIMATE_INFO *infoPtr)
return
TRUE
;
}
static
void
ANIMATE_Center
(
ANIMATE_INFO
*
infoPtr
)
{
int
x
,
y
,
dx
,
dy
;
RECT
Rect
;
HWND
hWnd
=
infoPtr
->
hWnd
;
HWND
hWndParent
=
GetWindowLongA
(
hWnd
,
GWL_HWNDPARENT
);
if
(
!
hWndParent
||
!
GetWindowRect
(
hWndParent
,
&
Rect
))
return
;
dx
=
Rect
.
right
-
Rect
.
left
+
1
;
dy
=
Rect
.
bottom
-
Rect
.
top
+
1
;
x
=
infoPtr
->
mah
.
dwWidth
<
dx
?
(
dx
-
infoPtr
->
mah
.
dwWidth
)
>>
1
:
0
;
y
=
infoPtr
->
mah
.
dwHeight
<
dy
?
(
dy
-
infoPtr
->
mah
.
dwHeight
)
>>
1
:
0
;
MoveWindow
(
hWnd
,
x
,
y
,
infoPtr
->
mah
.
dwWidth
,
infoPtr
->
mah
.
dwHeight
,
TRUE
);
}
static
LRESULT
ANIMATE_OpenA
(
HWND
hWnd
,
WPARAM
wParam
,
LPARAM
lParam
)
{
ANIMATE_INFO
*
infoPtr
=
ANIMATE_GetInfoPtr
(
hWnd
);
...
...
@@ -661,7 +678,9 @@ static LRESULT ANIMATE_OpenA(HWND hWnd, WPARAM wParam, LPARAM lParam)
}
if
(
GetWindowLongA
(
hWnd
,
GWL_STYLE
)
&
ACS_CENTER
)
{
FIXME
(
"ACS_CENTER: NIY
\n
"
);
ANIMATE_Center
(
infoPtr
);
}
else
{
/* MoveWindow(hWnd, 0, 0, infoPtr->mah.dwWidth, infoPtr->mah.dwHeight, FALSE);*/
SetWindowPos
(
hWnd
,
0
,
0
,
0
,
infoPtr
->
mah
.
dwWidth
,
infoPtr
->
mah
.
dwHeight
,
...
...
@@ -775,10 +794,10 @@ static LRESULT WINAPI ANIMATE_Size(HWND hWnd, WPARAM wParam, LPARAM lParam)
ANIMATE_INFO
*
infoPtr
=
ANIMATE_GetInfoPtr
(
hWnd
);
if
(
GetWindowLongA
(
hWnd
,
GWL_STYLE
)
&
ACS_CENTER
)
{
FIXME
(
"NIY
\n
"
);
if
(
infoPtr
->
hMMio
)
{
/* centers the animation in the control, invalidates the control
*/
ANIMATE_Center
(
infoPtr
);
}
InvalidateRect
(
hWnd
,
NULL
,
TRUE
);
}
...
...
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