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
ca30e48f
Commit
ca30e48f
authored
May 06, 2002
by
David Hammerton
Committed by
Alexandre Julliard
May 06, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added implementation of GetWindowInfo.
parent
20281102
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
80 additions
and
11 deletions
+80
-11
user32.spec
dlls/user/user32.spec
+1
-0
winuser.h
include/winuser.h
+27
-11
win.c
windows/win.c
+52
-0
No files found.
dlls/user/user32.spec
View file @
ca30e48f
...
...
@@ -327,6 +327,7 @@ debug_channels (accel caret class clipboard combo comm cursor dc ddeml dialog
@ stdcall GetWindowTextW(long ptr long) GetWindowTextW
@ stdcall GetWindowThreadProcessId(long ptr) GetWindowThreadProcessId
@ stdcall GetWindowWord(long long) GetWindowWord
@ stdcall GetWindowInfo(long ptr) GetWindowInfo
@ stdcall GrayStringA(long long ptr long long long long long long) GrayStringA
@ stdcall GrayStringW(long long ptr long long long long long long) GrayStringW
@ stdcall HideCaret(long) HideCaret
...
...
include/winuser.h
View file @
ca30e48f
...
...
@@ -3483,6 +3483,23 @@ typedef HDEVNOTIFY *PHDEVNOTIFY;
#define DEVICE_NOTIFY_WINDOW_HANDLE 0x00000000
/* used for GetWindowInfo() */
#define WS_ACTIVECAPTION 0x0001
typedef
struct
tagWINDOWINFO
{
DWORD
cbSize
;
RECT
rcWindow
;
RECT
rcClient
;
DWORD
dwStyle
;
DWORD
dwExStyle
;
DWORD
dwWindowStatus
;
UINT
cxWindowBorders
;
UINT
cyWindowBorders
;
ATOM
atomWindowType
;
WORD
wCreatorVersion
;
}
WINDOWINFO
,
*
PWINDOWINFO
,
*
LPWINDOWINFO
;
#define EnumTaskWindows(handle,proc,lparam) \
EnumThreadWindows(handle,proc,lparam)
#define OemToAnsiA OemToCharA
...
...
@@ -3937,25 +3954,24 @@ BOOL WINAPI GetUserObjectInformationW(HANDLE,INT,LPVOID,DWORD,LPDWORD);
#define GetUserObjectInformation WINELIB_NAME_AW(GetUserObjectInformation)
HWND
WINAPI
GetWindow
(
HWND
,
UINT
);
HDC
WINAPI
GetWindowDC
(
HWND
);
BOOL
WINAPI
GetWindowInfo
(
HWND
,
PWINDOWINFO
);
LONG
WINAPI
GetWindowLongA
(
HWND
,
INT
);
LONG
WINAPI
GetWindowLongW
(
HWND
,
INT
);
#define GetWindowLong WINELIB_NAME_AW(GetWindowLong)
BOOL
WINAPI
GetWindowPlacement
(
HWND
,
LPWINDOWPLACEMENT
);
BOOL
WINAPI
GetWindowRect
(
HWND
,
LPRECT
);
INT
WINAPI
GetWindowRgn
(
HWND
,
HRGN
);
BOOL
WINAPI
GetWindowPlacement
(
HWND
,
LPWINDOWPLACEMENT
);
BOOL
WINAPI
GetWindowRect
(
HWND
,
LPRECT
);
INT
WINAPI
GetWindowRgn
(
HWND
,
HRGN
);
HWINSTA
WINAPI
GetProcessWindowStation
(
void
);
#define GetWindowTask(hwnd) ((HTASK)GetWindowThreadProcessId(hwnd,NULL))
INT
WINAPI
GetWindowTextA
(
HWND
,
LPSTR
,
INT
);
INT
WINAPI
GetWindowTextW
(
HWND
,
LPWSTR
,
INT
);
INT
WINAPI
GetWindowTextA
(
HWND
,
LPSTR
,
INT
);
INT
WINAPI
GetWindowTextW
(
HWND
,
LPWSTR
,
INT
);
#define GetWindowText WINELIB_NAME_AW(GetWindowText)
INT
WINAPI
GetWindowTextLengthA
(
HWND
);
INT
WINAPI
GetWindowTextLengthW
(
HWND
);
INT
WINAPI
GetWindowTextLengthA
(
HWND
);
INT
WINAPI
GetWindowTextLengthW
(
HWND
);
#define GetWindowTextLength WINELIB_NAME_AW(GetWindowTextLength)
WORD
WINAPI
GetWindowWord
(
HWND
,
INT
);
BOOL
WINAPI
GrayStringA
(
HDC
,
HBRUSH
,
GRAYSTRINGPROC
,
LPARAM
,
INT
,
INT
,
INT
,
INT
,
INT
);
BOOL
WINAPI
GrayStringW
(
HDC
,
HBRUSH
,
GRAYSTRINGPROC
,
LPARAM
,
INT
,
INT
,
INT
,
INT
,
INT
);
BOOL
WINAPI
GrayStringA
(
HDC
,
HBRUSH
,
GRAYSTRINGPROC
,
LPARAM
,
INT
,
INT
,
INT
,
INT
,
INT
);
BOOL
WINAPI
GrayStringW
(
HDC
,
HBRUSH
,
GRAYSTRINGPROC
,
LPARAM
,
INT
,
INT
,
INT
,
INT
,
INT
);
#define GrayString WINELIB_NAME_AW(GrayString)
BOOL
WINAPI
HideCaret
(
HWND
);
BOOL
WINAPI
HiliteMenuItem
(
HWND
,
HMENU
,
UINT
,
UINT
);
...
...
windows/win.c
View file @
ca30e48f
...
...
@@ -3340,3 +3340,55 @@ UINT WINAPI GetWindowModuleFileNameW( HWND hwnd, LPSTR lpszFileName, UINT cchFil
hwnd
,
lpszFileName
,
cchFileNameMax
);
return
0
;
}
/******************************************************************************
* GetWindowInfo (USER32.@)
* hwnd: in
* pwi: out.
* MS Documentation mentions that pwi->cbSize must be set to SIZEOF(WINDOWINFO)
* this may be because this structure changed over time. If this is the
* the case, then please: FIXME.
* Using the structure described in MSDN for 98/ME/NT(4.0 SP3)/2000/XP.
*/
BOOL
WINAPI
GetWindowInfo
(
HWND
hwnd
,
PWINDOWINFO
pwi
)
{
WND
*
wndInfo
=
NULL
;
if
(
!
pwi
)
return
FALSE
;
if
(
pwi
->
cbSize
!=
sizeof
(
WINDOWINFO
))
{
FIXME
(
"windowinfo->cbSize != sizeof(WINDOWINFO). Please report
\n
"
);
return
FALSE
;
}
wndInfo
=
WIN_GetPtr
(
hwnd
);
if
(
!
wndInfo
)
return
FALSE
;
if
(
wndInfo
==
WND_OTHER_PROCESS
)
{
FIXME
(
"window belong to other process
\n
"
);
return
FALSE
;
}
pwi
->
rcWindow
=
wndInfo
->
rectWindow
;
pwi
->
rcClient
=
wndInfo
->
rectClient
;
pwi
->
dwStyle
=
wndInfo
->
dwStyle
;
pwi
->
dwExStyle
=
wndInfo
->
dwExStyle
;
pwi
->
dwWindowStatus
=
((
GetActiveWindow
()
==
hwnd
)
?
WS_ACTIVECAPTION
:
0
);
/* if active WS_ACTIVECAPTION, else 0 */
pwi
->
cxWindowBorders
=
((
wndInfo
->
dwStyle
&
WS_BORDER
)
?
GetSystemMetrics
(
SM_CXBORDER
)
:
0
);
pwi
->
cyWindowBorders
=
((
wndInfo
->
dwStyle
&
WS_BORDER
)
?
GetSystemMetrics
(
SM_CYBORDER
)
:
0
);
/* above two: I'm presuming that borders widths are the same
* for each window - so long as its actually using a border.. */
pwi
->
atomWindowType
=
GetClassLongA
(
hwnd
,
GCW_ATOM
);
pwi
->
wCreatorVersion
=
GetVersion
();
/* Docs say this should be the version that
* CREATED the window. But eh?.. Isn't that just the
* version we are running.. Unless ofcourse its some wacky
* RPC stuff or something */
WIN_ReleasePtr
(
wndInfo
);
return
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