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
cc091963
Commit
cc091963
authored
Dec 08, 2003
by
Kevin Koltzau
Committed by
Alexandre Julliard
Dec 08, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Implemented GetTitleBarInfo.
parent
58c185ec
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
114 additions
and
1 deletion
+114
-1
user32.spec
dlls/user/user32.spec
+1
-1
winuser.h
include/winuser.h
+44
-0
nonclient.c
windows/nonclient.c
+69
-0
No files found.
dlls/user/user32.spec
View file @
cc091963
...
@@ -304,7 +304,7 @@
...
@@ -304,7 +304,7 @@
@ stdcall GetTabbedTextExtentA(long str long long ptr)
@ stdcall GetTabbedTextExtentA(long str long long ptr)
@ stdcall GetTabbedTextExtentW(long wstr long long ptr)
@ stdcall GetTabbedTextExtentW(long wstr long long ptr)
@ stdcall GetThreadDesktop(long)
@ stdcall GetThreadDesktop(long)
# @ stub GetTitleBarInfo
@ stdcall GetTitleBarInfo(long ptr)
@ stdcall GetTopWindow(long)
@ stdcall GetTopWindow(long)
@ stdcall GetUpdateRect(long ptr long)
@ stdcall GetUpdateRect(long ptr long)
@ stdcall GetUpdateRgn(long long long)
@ stdcall GetUpdateRgn(long long long)
...
...
include/winuser.h
View file @
cc091963
...
@@ -3544,6 +3544,16 @@ typedef struct tagWINDOWINFO {
...
@@ -3544,6 +3544,16 @@ typedef struct tagWINDOWINFO {
WORD
wCreatorVersion
;
WORD
wCreatorVersion
;
}
WINDOWINFO
,
*
PWINDOWINFO
,
*
LPWINDOWINFO
;
}
WINDOWINFO
,
*
PWINDOWINFO
,
*
LPWINDOWINFO
;
/* used for GetTitleBarInfo() */
#define CCHILDREN_TITLEBAR 5
typedef
struct
tagTITLEBARINFO
{
DWORD
cbSize
;
RECT
rcTitleBar
;
DWORD
rgstate
[
CCHILDREN_TITLEBAR
+
1
];
}
TITLEBARINFO
,
*
PTITLEBARINFO
,
*
LPTITLEBARINFO
;
/* SetWinEventHook() flags */
/* SetWinEventHook() flags */
#define WINEVENT_OUTOFCONTEXT 0x0
#define WINEVENT_OUTOFCONTEXT 0x0
#define WINEVENT_SKIPOWNTHREAD 0x1
#define WINEVENT_SKIPOWNTHREAD 0x1
...
@@ -3663,6 +3673,39 @@ typedef struct tagWINDOWINFO {
...
@@ -3663,6 +3673,39 @@ typedef struct tagWINDOWINFO {
#define ALERT_SYSTEM_CRITICAL 5
#define ALERT_SYSTEM_CRITICAL 5
#define CALERT_SYSTEM 6
#define CALERT_SYSTEM 6
/* System state flags */
#define STATE_SYSTEM_UNAVAILABLE 0x00000001
#define STATE_SYSTEM_SELECTED 0x00000002
#define STATE_SYSTEM_FOCUSED 0x00000004
#define STATE_SYSTEM_PRESSED 0x00000008
#define STATE_SYSTEM_CHECKED 0x00000010
#define STATE_SYSTEM_MIXED 0x00000020
#define STATE_SYSTEM_INDETERMINATE STATE_SYSTEM_MIXED
#define STATE_SYSTEM_READONLY 0x00000040
#define STATE_SYSTEM_HOTTRACKED 0x00000080
#define STATE_SYSTEM_DEFAULT 0x00000100
#define STATE_SYSTEM_EXPANDED 0x00000200
#define STATE_SYSTEM_COLLAPSED 0x00000400
#define STATE_SYSTEM_BUSY 0x00000800
#define STATE_SYSTEM_FLOATING 0x00001000
#define STATE_SYSTEM_MARQUEED 0x00002000
#define STATE_SYSTEM_ANIMATED 0x00004000
#define STATE_SYSTEM_INVISIBLE 0x00008000
#define STATE_SYSTEM_OFFSCREEN 0x00010000
#define STATE_SYSTEM_SIZEABLE 0x00020000
#define STATE_SYSTEM_MOVEABLE 0x00040000
#define STATE_SYSTEM_SELFVOICING 0x00080000
#define STATE_SYSTEM_FOCUSABLE 0x00100000
#define STATE_SYSTEM_SELECTABLE 0x00200000
#define STATE_SYSTEM_LINKED 0x00400000
#define STATE_SYSTEM_TRAVERSED 0x00800000
#define STATE_SYSTEM_MULTISELECTABLE 0x01000000
#define STATE_SYSTEM_EXTSELECTABLE 0x02000000
#define STATE_SYSTEM_ALERT_LOW 0x04000000
#define STATE_SYSTEM_ALERT_MEDIUM 0x08000000
#define STATE_SYSTEM_ALERT_HIGH 0x10000000
#define STATE_SYSTEM_PROTECTED 0x20000000
#define STATE_SYSTEM_VALID 0x3FFFFFFF
#define EnumTaskWindows(handle,proc,lparam) \
#define EnumTaskWindows(handle,proc,lparam) \
EnumThreadWindows(handle,proc,lparam)
EnumThreadWindows(handle,proc,lparam)
...
@@ -4125,6 +4168,7 @@ INT WINAPI GetSystemMetrics(INT);
...
@@ -4125,6 +4168,7 @@ INT WINAPI GetSystemMetrics(INT);
DWORD
WINAPI
GetTabbedTextExtentA
(
HDC
,
LPCSTR
,
INT
,
INT
,
const
INT
*
);
DWORD
WINAPI
GetTabbedTextExtentA
(
HDC
,
LPCSTR
,
INT
,
INT
,
const
INT
*
);
DWORD
WINAPI
GetTabbedTextExtentW
(
HDC
,
LPCWSTR
,
INT
,
INT
,
const
INT
*
);
DWORD
WINAPI
GetTabbedTextExtentW
(
HDC
,
LPCWSTR
,
INT
,
INT
,
const
INT
*
);
#define GetTabbedTextExtent WINELIB_NAME_AW(GetTabbedTextExtent)
#define GetTabbedTextExtent WINELIB_NAME_AW(GetTabbedTextExtent)
BOOL
WINAPI
GetTitleBarInfo
(
HWND
,
PTITLEBARINFO
);
HWND
WINAPI
GetTopWindow
(
HWND
);
HWND
WINAPI
GetTopWindow
(
HWND
);
BOOL
WINAPI
GetUpdateRect
(
HWND
,
LPRECT
,
BOOL
);
BOOL
WINAPI
GetUpdateRect
(
HWND
,
LPRECT
,
BOOL
);
INT
WINAPI
GetUpdateRgn
(
HWND
,
HRGN
,
BOOL
);
INT
WINAPI
GetUpdateRgn
(
HWND
,
HRGN
,
BOOL
);
...
...
windows/nonclient.c
View file @
cc091963
...
@@ -2259,3 +2259,72 @@ BOOL NC_DrawGrayButton(HDC hdc, int x, int y)
...
@@ -2259,3 +2259,72 @@ BOOL NC_DrawGrayButton(HDC hdc, int x, int y)
return
TRUE
;
return
TRUE
;
}
}
/***********************************************************************
* GetTitleBarInfo (USER32.@)
* TODO: Handle STATE_SYSTEM_PRESSED
*/
BOOL
WINAPI
GetTitleBarInfo
(
HWND
hwnd
,
PTITLEBARINFO
tbi
)
{
DWORD
dwStyle
;
DWORD
dwExStyle
;
RECT
wndRect
;
TRACE
(
"(%p %p)
\n
"
,
hwnd
,
tbi
);
if
(
tbi
->
cbSize
!=
sizeof
(
TITLEBARINFO
))
{
TRACE
(
"Invalid TITLEBARINFO size: %ld
\n
"
,
tbi
->
cbSize
);
SetLastError
(
ERROR_INVALID_PARAMETER
);
return
FALSE
;
}
dwStyle
=
GetWindowLongW
(
hwnd
,
GWL_STYLE
);
dwExStyle
=
GetWindowLongW
(
hwnd
,
GWL_EXSTYLE
);
NC_GetInsideRect
(
hwnd
,
&
tbi
->
rcTitleBar
);
GetWindowRect
(
hwnd
,
&
wndRect
);
tbi
->
rcTitleBar
.
top
+=
wndRect
.
top
;
tbi
->
rcTitleBar
.
left
+=
wndRect
.
left
;
tbi
->
rcTitleBar
.
right
+=
wndRect
.
left
;
tbi
->
rcTitleBar
.
bottom
=
tbi
->
rcTitleBar
.
top
;
if
(
dwExStyle
&
WS_EX_TOOLWINDOW
)
tbi
->
rcTitleBar
.
bottom
+=
GetSystemMetrics
(
SM_CYSMCAPTION
);
else
{
tbi
->
rcTitleBar
.
bottom
+=
GetSystemMetrics
(
SM_CYCAPTION
);
tbi
->
rcTitleBar
.
left
+=
GetSystemMetrics
(
SM_CXSIZE
);
}
ZeroMemory
(
&
tbi
->
rgstate
,
sizeof
(
tbi
->
rgstate
));
/* Does the title bar always have STATE_SYSTEM_FOCUSABLE?
* Under XP it seems to
*/
tbi
->
rgstate
[
0
]
=
STATE_SYSTEM_FOCUSABLE
;
if
(
dwStyle
&
WS_CAPTION
)
{
tbi
->
rgstate
[
1
]
=
STATE_SYSTEM_INVISIBLE
;
if
(
dwStyle
&
WS_SYSMENU
)
{
if
(
!
(
dwStyle
&
(
WS_MINIMIZEBOX
|
WS_MAXIMIZEBOX
)))
{
tbi
->
rgstate
[
2
]
=
STATE_SYSTEM_INVISIBLE
;
tbi
->
rgstate
[
3
]
=
STATE_SYSTEM_INVISIBLE
;
}
else
{
if
(
!
(
dwStyle
&
WS_MINIMIZEBOX
))
tbi
->
rgstate
[
2
]
=
STATE_SYSTEM_UNAVAILABLE
;
if
(
!
(
dwStyle
&
WS_MAXIMIZEBOX
))
tbi
->
rgstate
[
3
]
=
STATE_SYSTEM_UNAVAILABLE
;
}
if
(
!
(
dwExStyle
&
WS_EX_CONTEXTHELP
))
tbi
->
rgstate
[
4
]
=
STATE_SYSTEM_INVISIBLE
;
if
(
GetClassLongW
(
hwnd
,
GCL_STYLE
)
&
CS_NOCLOSE
)
tbi
->
rgstate
[
5
]
=
STATE_SYSTEM_UNAVAILABLE
;
}
else
{
tbi
->
rgstate
[
2
]
=
STATE_SYSTEM_INVISIBLE
;
tbi
->
rgstate
[
3
]
=
STATE_SYSTEM_INVISIBLE
;
tbi
->
rgstate
[
4
]
=
STATE_SYSTEM_INVISIBLE
;
tbi
->
rgstate
[
5
]
=
STATE_SYSTEM_INVISIBLE
;
}
}
else
tbi
->
rgstate
[
0
]
|=
STATE_SYSTEM_INVISIBLE
;
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