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
f22760d2
Commit
f22760d2
authored
Oct 07, 2015
by
Jactry Zeng
Committed by
Alexandre Julliard
Oct 12, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32: Implement semi-stub for FlashWindowEx.
Signed-off-by:
Jactry Zeng
<
jzeng@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
d2d11419
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
48 additions
and
29 deletions
+48
-29
win.c
dlls/user32/tests/win.c
+9
-10
win.c
dlls/user32/win.c
+39
-19
No files found.
dlls/user32/tests/win.c
View file @
f22760d2
...
...
@@ -7085,14 +7085,14 @@ static void test_FlashWindow(void)
SetLastError
(
0xdeadbeef
);
ret
=
pFlashWindow
(
NULL
,
TRUE
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"FlashWindow returned with %d
\n
"
,
GetLastError
()
);
DestroyWindow
(
hwnd
);
SetLastError
(
0xdeadbeef
);
ret
=
pFlashWindow
(
hwnd
,
TRUE
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"FlashWindow returned with %d
\n
"
,
GetLastError
()
);
}
...
...
@@ -7119,13 +7119,13 @@ static void test_FlashWindowEx(void)
finfo
.
hwnd
=
NULL
;
SetLastError
(
0xdeadbeef
);
ret
=
pFlashWindowEx
(
&
finfo
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"FlashWindowEx returned with %d
\n
"
,
GetLastError
());
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"FlashWindowEx returned with %d
\n
"
,
GetLastError
());
finfo
.
hwnd
=
hwnd
;
SetLastError
(
0xdeadbeef
);
ret
=
pFlashWindowEx
(
NULL
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_NOACCESS
,
ok
(
!
ret
&&
GetLastError
()
==
ERROR_NOACCESS
,
"FlashWindowEx returned with %d
\n
"
,
GetLastError
());
SetLastError
(
0xdeadbeef
);
...
...
@@ -7135,13 +7135,13 @@ static void test_FlashWindowEx(void)
finfo
.
cbSize
=
sizeof
(
FLASHWINFO
)
-
1
;
SetLastError
(
0xdeadbeef
);
ret
=
pFlashWindowEx
(
&
finfo
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"FlashWindowEx succeeded
\n
"
);
finfo
.
cbSize
=
sizeof
(
FLASHWINFO
)
+
1
;
SetLastError
(
0xdeadbeef
);
ret
=
pFlashWindowEx
(
&
finfo
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"FlashWindowEx succeeded
\n
"
);
finfo
.
cbSize
=
sizeof
(
FLASHWINFO
);
...
...
@@ -7149,7 +7149,7 @@ static void test_FlashWindowEx(void)
SetLastError
(
0xdeadbeef
);
ret
=
pFlashWindowEx
(
&
finfo
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INVALID_PARAMETER
,
"FlashWindowEx returned with %d
\n
"
,
GetLastError
());
ok
(
finfo
.
cbSize
==
sizeof
(
FLASHWINFO
),
"FlashWindowEx modified cdSize to %x
\n
"
,
finfo
.
cbSize
);
...
...
@@ -7165,7 +7165,7 @@ static void test_FlashWindowEx(void)
SetLastError
(
0xdeadbeef
);
ret
=
pFlashWindowEx
(
NULL
);
todo_wine
ok
(
!
ret
&&
GetLastError
()
==
ERROR_NOACCESS
,
ok
(
!
ret
&&
GetLastError
()
==
ERROR_NOACCESS
,
"FlashWindowEx returned with %d
\n
"
,
GetLastError
());
SetLastError
(
0xdeadbeef
);
...
...
@@ -7180,7 +7180,6 @@ static void test_FlashWindowEx(void)
finfo
.
dwFlags
=
FLASHW_STOP
;
SetLastError
(
0xdeadbeef
);
ret
=
pFlashWindowEx
(
&
finfo
);
todo_wine
ok
(
prev
!=
ret
,
"previous window state should be different
\n
"
);
DestroyWindow
(
hwnd
);
...
...
dlls/user32/win.c
View file @
f22760d2
...
...
@@ -3413,17 +3413,45 @@ BOOL WINAPI AnyPopup(void)
*/
BOOL
WINAPI
FlashWindow
(
HWND
hWnd
,
BOOL
bInvert
)
{
FLASHWINFO
finfo
;
finfo
.
cbSize
=
sizeof
(
FLASHWINFO
);
finfo
.
dwFlags
=
bInvert
?
FLASHW_ALL
:
FLASHW_STOP
;
finfo
.
uCount
=
1
;
finfo
.
dwTimeout
=
0
;
finfo
.
hwnd
=
hWnd
;
return
FlashWindowEx
(
&
finfo
);
}
/*******************************************************************
* FlashWindowEx (USER32.@)
*/
BOOL
WINAPI
FlashWindowEx
(
PFLASHWINFO
pfinfo
)
{
WND
*
wndPtr
;
TRACE
(
"%p
\n
"
,
hWnd
);
TRACE
(
"%p
\n
"
,
pfinfo
->
hwnd
);
if
(
!
pfinfo
)
{
SetLastError
(
ERROR_NOACCESS
);
return
FALSE
;
}
if
(
!
pfinfo
->
hwnd
||
pfinfo
->
cbSize
!=
sizeof
(
FLASHWINFO
)
||
!
IsWindow
(
pfinfo
->
hwnd
))
{
SetLastError
(
ERROR_INVALID_PARAMETER
);
return
FALSE
;
}
FIXME
(
"%p - semi-stub
\n
"
,
pfinfo
);
if
(
IsIconic
(
hW
nd
))
if
(
IsIconic
(
pfinfo
->
hw
nd
))
{
RedrawWindow
(
hW
nd
,
0
,
0
,
RDW_INVALIDATE
|
RDW_ERASE
|
RDW_UPDATENOW
|
RDW_FRAME
);
RedrawWindow
(
pfinfo
->
hw
nd
,
0
,
0
,
RDW_INVALIDATE
|
RDW_ERASE
|
RDW_UPDATENOW
|
RDW_FRAME
);
wndPtr
=
WIN_GetPtr
(
hWnd
);
wndPtr
=
WIN_GetPtr
(
pfinfo
->
hwnd
);
if
(
!
wndPtr
||
wndPtr
==
WND_OTHER_PROCESS
||
wndPtr
==
WND_DESKTOP
)
return
FALSE
;
if
(
bInvert
&&
!
(
wndPtr
->
flags
&
WIN_NCACTIVATED
))
if
(
pfinfo
->
dwFlags
&&
!
(
wndPtr
->
flags
&
WIN_NCACTIVATED
))
{
wndPtr
->
flags
|=
WIN_NCACTIVATED
;
}
...
...
@@ -3437,30 +3465,22 @@ BOOL WINAPI FlashWindow( HWND hWnd, BOOL bInvert )
else
{
WPARAM
wparam
;
HWND
hwnd
=
pfinfo
->
hwnd
;
wndPtr
=
WIN_GetPtr
(
hWnd
);
wndPtr
=
WIN_GetPtr
(
hwnd
);
if
(
!
wndPtr
||
wndPtr
==
WND_OTHER_PROCESS
||
wndPtr
==
WND_DESKTOP
)
return
FALSE
;
h
W
nd
=
wndPtr
->
obj
.
handle
;
/* make it a full handle */
h
w
nd
=
wndPtr
->
obj
.
handle
;
/* make it a full handle */
if
(
bInvert
)
wparam
=
!
(
wndPtr
->
flags
&
WIN_NCACTIVATED
);
else
wparam
=
(
h
W
nd
==
GetForegroundWindow
());
if
(
pfinfo
->
dwFlags
)
wparam
=
!
(
wndPtr
->
flags
&
WIN_NCACTIVATED
);
else
wparam
=
(
h
w
nd
==
GetForegroundWindow
());
WIN_ReleasePtr
(
wndPtr
);
SendMessageW
(
h
W
nd
,
WM_NCACTIVATE
,
wparam
,
0
);
SendMessageW
(
h
w
nd
,
WM_NCACTIVATE
,
wparam
,
0
);
return
wparam
;
}
}
/*******************************************************************
* FlashWindowEx (USER32.@)
*/
BOOL
WINAPI
FlashWindowEx
(
PFLASHWINFO
pfwi
)
{
FIXME
(
"%p
\n
"
,
pfwi
);
return
TRUE
;
}
/*******************************************************************
* GetWindowContextHelpId (USER32.@)
*/
DWORD
WINAPI
GetWindowContextHelpId
(
HWND
hwnd
)
...
...
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