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
c8ce866a
Commit
c8ce866a
authored
May 10, 2006
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user: Make the WINDOWPROCTYPE enum private to winproc.c.
parent
4cc498f8
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
23 additions
and
28 deletions
+23
-28
class.c
dlls/user/class.c
+3
-3
win.c
dlls/user/win.c
+11
-16
winproc.c
dlls/user/winproc.c
+8
-0
winproc.h
dlls/user/winproc.h
+1
-9
No files found.
dlls/user/class.c
View file @
c8ce866a
...
@@ -520,9 +520,9 @@ void CLASS_RegisterBuiltinClasses(void)
...
@@ -520,9 +520,9 @@ void CLASS_RegisterBuiltinClasses(void)
* Add a new window using this class, and set the necessary
* Add a new window using this class, and set the necessary
* information inside the window structure.
* information inside the window structure.
*/
*/
void
CLASS_AddWindow
(
CLASS
*
class
,
WND
*
win
,
WINDOWPROCTYPE
typ
e
)
void
CLASS_AddWindow
(
CLASS
*
class
,
WND
*
win
,
BOOL
unicod
e
)
{
{
if
(
type
==
WIN_PROC_32W
)
if
(
unicode
)
{
{
if
(
!
(
win
->
winproc
=
class
->
winprocW
))
win
->
winproc
=
class
->
winprocA
;
if
(
!
(
win
->
winproc
=
class
->
winprocW
))
win
->
winproc
=
class
->
winprocA
;
}
}
...
@@ -532,7 +532,7 @@ void CLASS_AddWindow( CLASS *class, WND *win, WINDOWPROCTYPE type )
...
@@ -532,7 +532,7 @@ void CLASS_AddWindow( CLASS *class, WND *win, WINDOWPROCTYPE type )
}
}
win
->
class
=
class
;
win
->
class
=
class
;
win
->
clsStyle
=
class
->
style
;
win
->
clsStyle
=
class
->
style
;
if
(
WINPROC_IsUnicode
(
win
->
winproc
,
(
type
==
WIN_PROC_32W
)
))
win
->
flags
|=
WIN_ISUNICODE
;
if
(
WINPROC_IsUnicode
(
win
->
winproc
,
unicode
))
win
->
flags
|=
WIN_ISUNICODE
;
}
}
...
...
dlls/user/win.c
View file @
c8ce866a
...
@@ -55,7 +55,7 @@ static void *user_handles[NB_USER_HANDLES];
...
@@ -55,7 +55,7 @@ static void *user_handles[NB_USER_HANDLES];
* Create a window handle with the server.
* Create a window handle with the server.
*/
*/
static
WND
*
create_window_handle
(
HWND
parent
,
HWND
owner
,
ATOM
atom
,
static
WND
*
create_window_handle
(
HWND
parent
,
HWND
owner
,
ATOM
atom
,
HINSTANCE
instance
,
WINDOWPROCTYPE
typ
e
)
HINSTANCE
instance
,
BOOL
unicod
e
)
{
{
WORD
index
;
WORD
index
;
WND
*
win
;
WND
*
win
;
...
@@ -125,7 +125,7 @@ static WND *create_window_handle( HWND parent, HWND owner, ATOM atom,
...
@@ -125,7 +125,7 @@ static WND *create_window_handle( HWND parent, HWND owner, ATOM atom,
win
->
flags
=
0
;
win
->
flags
=
0
;
win
->
cbWndExtra
=
extra_bytes
;
win
->
cbWndExtra
=
extra_bytes
;
memset
(
win
->
wExtra
,
0
,
extra_bytes
);
memset
(
win
->
wExtra
,
0
,
extra_bytes
);
CLASS_AddWindow
(
class
,
win
,
typ
e
);
CLASS_AddWindow
(
class
,
win
,
unicod
e
);
return
win
;
return
win
;
}
}
...
@@ -846,26 +846,21 @@ static void dump_window_styles( DWORD style, DWORD exstyle )
...
@@ -846,26 +846,21 @@ static void dump_window_styles( DWORD style, DWORD exstyle )
*
*
* Implementation of CreateWindowEx().
* Implementation of CreateWindowEx().
*/
*/
static
HWND
WIN_CreateWindowEx
(
CREATESTRUCTA
*
cs
,
ATOM
classAtom
,
static
HWND
WIN_CreateWindowEx
(
CREATESTRUCTA
*
cs
,
ATOM
classAtom
,
UINT
flags
)
WINDOWPROCTYPE
type
)
{
{
INT
sw
=
SW_SHOW
;
INT
sw
=
SW_SHOW
;
WND
*
wndPtr
;
WND
*
wndPtr
;
HWND
hwnd
,
parent
,
owner
,
top_child
=
0
;
HWND
hwnd
,
parent
,
owner
,
top_child
=
0
;
BOOL
unicode
=
(
type
==
WIN_PROC_32W
)
;
BOOL
unicode
=
(
flags
&
WIN_ISUNICODE
)
!=
0
;
MDICREATESTRUCTA
mdi_cs
;
MDICREATESTRUCTA
mdi_cs
;
TRACE
(
"%s %s ex=%08lx style=%08lx %d,%d %dx%d parent=%p menu=%p inst=%p params=%p
\n
"
,
TRACE
(
"%s %s ex=%08lx style=%08lx %d,%d %dx%d parent=%p menu=%p inst=%p params=%p
\n
"
,
(
type
==
WIN_PROC_32W
)
?
debugstr_w
((
LPCWSTR
)
cs
->
lpszName
)
:
debugstr_a
(
cs
->
lpszName
),
unicode
?
debugstr_w
((
LPCWSTR
)
cs
->
lpszName
)
:
debugstr_a
(
cs
->
lpszName
),
(
type
==
WIN_PROC_32W
)
?
debugstr_w
((
LPCWSTR
)
cs
->
lpszClass
)
:
debugstr_a
(
cs
->
lpszClass
),
unicode
?
debugstr_w
((
LPCWSTR
)
cs
->
lpszClass
)
:
debugstr_a
(
cs
->
lpszClass
),
cs
->
dwExStyle
,
cs
->
style
,
cs
->
x
,
cs
->
y
,
cs
->
cx
,
cs
->
cy
,
cs
->
dwExStyle
,
cs
->
style
,
cs
->
x
,
cs
->
y
,
cs
->
cx
,
cs
->
cy
,
cs
->
hwndParent
,
cs
->
hMenu
,
cs
->
hInstance
,
cs
->
lpCreateParams
);
cs
->
hwndParent
,
cs
->
hMenu
,
cs
->
hInstance
,
cs
->
lpCreateParams
);
if
(
TRACE_ON
(
win
))
dump_window_styles
(
cs
->
style
,
cs
->
dwExStyle
);
if
(
TRACE_ON
(
win
))
dump_window_styles
(
cs
->
style
,
cs
->
dwExStyle
);
TRACE
(
"winproc type is %d (%s)
\n
"
,
type
,
(
type
==
WIN_PROC_16
)
?
"WIN_PROC_16"
:
((
type
==
WIN_PROC_32A
)
?
"WIN_PROC_32A"
:
"WIN_PROC_32W"
)
);
/* Fix the styles for MDI children */
/* Fix the styles for MDI children */
if
(
cs
->
dwExStyle
&
WS_EX_MDICHILD
)
if
(
cs
->
dwExStyle
&
WS_EX_MDICHILD
)
{
{
...
@@ -976,7 +971,7 @@ static HWND WIN_CreateWindowEx( CREATESTRUCTA *cs, ATOM classAtom,
...
@@ -976,7 +971,7 @@ static HWND WIN_CreateWindowEx( CREATESTRUCTA *cs, ATOM classAtom,
/* Create the window structure */
/* Create the window structure */
if
(
!
(
wndPtr
=
create_window_handle
(
parent
,
owner
,
classAtom
,
cs
->
hInstance
,
typ
e
)))
if
(
!
(
wndPtr
=
create_window_handle
(
parent
,
owner
,
classAtom
,
cs
->
hInstance
,
unicod
e
)))
return
0
;
return
0
;
hwnd
=
wndPtr
->
hwndSelf
;
hwnd
=
wndPtr
->
hwndSelf
;
...
@@ -995,7 +990,7 @@ static HWND WIN_CreateWindowEx( CREATESTRUCTA *cs, ATOM classAtom,
...
@@ -995,7 +990,7 @@ static HWND WIN_CreateWindowEx( CREATESTRUCTA *cs, ATOM classAtom,
wndPtr
->
hIcon
=
0
;
wndPtr
->
hIcon
=
0
;
wndPtr
->
hIconSmall
=
0
;
wndPtr
->
hIconSmall
=
0
;
wndPtr
->
hSysMenu
=
0
;
wndPtr
->
hSysMenu
=
0
;
if
(
type
!=
WIN_PROC_16
)
wndPtr
->
flags
|=
WIN_ISWIN32
;
wndPtr
->
flags
|=
(
flags
&
WIN_ISWIN32
)
;
if
(
wndPtr
->
dwStyle
&
WS_SYSMENU
)
SetSystemMenu
(
hwnd
,
0
);
if
(
wndPtr
->
dwStyle
&
WS_SYSMENU
)
SetSystemMenu
(
hwnd
,
0
);
...
@@ -1172,7 +1167,7 @@ HWND16 WINAPI CreateWindowEx16( DWORD exStyle, LPCSTR className,
...
@@ -1172,7 +1167,7 @@ HWND16 WINAPI CreateWindowEx16( DWORD exStyle, LPCSTR className,
cs
.
lpszClass
=
className
;
cs
.
lpszClass
=
className
;
cs
.
dwExStyle
=
exStyle
;
cs
.
dwExStyle
=
exStyle
;
return
HWND_16
(
WIN_CreateWindowEx
(
&
cs
,
classAtom
,
WIN_PROC_16
));
return
HWND_16
(
WIN_CreateWindowEx
(
&
cs
,
classAtom
,
0
));
}
}
...
@@ -1225,7 +1220,7 @@ HWND WINAPI CreateWindowExA( DWORD exStyle, LPCSTR className,
...
@@ -1225,7 +1220,7 @@ HWND WINAPI CreateWindowExA( DWORD exStyle, LPCSTR className,
cs
.
lpszClass
=
className
;
cs
.
lpszClass
=
className
;
cs
.
dwExStyle
=
exStyle
;
cs
.
dwExStyle
=
exStyle
;
return
WIN_CreateWindowEx
(
&
cs
,
classAtom
,
WIN_
PROC_32A
);
return
WIN_CreateWindowEx
(
&
cs
,
classAtom
,
WIN_
ISWIN32
);
}
}
...
@@ -1280,7 +1275,7 @@ HWND WINAPI CreateWindowExW( DWORD exStyle, LPCWSTR className,
...
@@ -1280,7 +1275,7 @@ HWND WINAPI CreateWindowExW( DWORD exStyle, LPCWSTR className,
/* Note: we rely on the fact that CREATESTRUCTA and */
/* Note: we rely on the fact that CREATESTRUCTA and */
/* CREATESTRUCTW have the same layout. */
/* CREATESTRUCTW have the same layout. */
return
WIN_CreateWindowEx
(
(
CREATESTRUCTA
*
)
&
cs
,
classAtom
,
WIN_
PROC_32W
);
return
WIN_CreateWindowEx
(
(
CREATESTRUCTA
*
)
&
cs
,
classAtom
,
WIN_
ISWIN32
|
WIN_ISUNICODE
);
}
}
...
...
dlls/user/winproc.c
View file @
c8ce866a
...
@@ -79,6 +79,14 @@ typedef struct tagWINDOWPROC
...
@@ -79,6 +79,14 @@ typedef struct tagWINDOWPROC
WNDPROC16
proc16
;
/* 16-bit window proc */
WNDPROC16
proc16
;
/* 16-bit window proc */
}
WINDOWPROC
;
}
WINDOWPROC
;
typedef
enum
{
WIN_PROC_INVALID
,
WIN_PROC_16
,
WIN_PROC_32A
,
WIN_PROC_32W
}
WINDOWPROCTYPE
;
#define WINPROC_HANDLE (~0UL >> 16)
#define WINPROC_HANDLE (~0UL >> 16)
#define MAX_WINPROCS (0x10000 / sizeof(WINDOWPROC))
#define MAX_WINPROCS (0x10000 / sizeof(WINDOWPROC))
...
...
dlls/user/winproc.h
View file @
c8ce866a
...
@@ -28,14 +28,6 @@
...
@@ -28,14 +28,6 @@
#include "wine/winbase16.h"
#include "wine/winbase16.h"
#include "winnls.h"
#include "winnls.h"
typedef
enum
{
WIN_PROC_INVALID
,
WIN_PROC_16
,
WIN_PROC_32A
,
WIN_PROC_32W
}
WINDOWPROCTYPE
;
typedef
struct
typedef
struct
{
{
WPARAM16
wParam
;
WPARAM16
wParam
;
...
@@ -134,7 +126,7 @@ inline static void unmap_str_16_to_32W( LPCWSTR str )
...
@@ -134,7 +126,7 @@ inline static void unmap_str_16_to_32W( LPCWSTR str )
struct
tagCLASS
;
/* opaque structure */
struct
tagCLASS
;
/* opaque structure */
struct
tagWND
;
struct
tagWND
;
extern
void
CLASS_RegisterBuiltinClasses
(
void
);
extern
void
CLASS_RegisterBuiltinClasses
(
void
);
extern
void
CLASS_AddWindow
(
struct
tagCLASS
*
class
,
struct
tagWND
*
win
,
WINDOWPROCTYPE
typ
e
);
extern
void
CLASS_AddWindow
(
struct
tagCLASS
*
class
,
struct
tagWND
*
win
,
BOOL
unicod
e
);
extern
void
CLASS_FreeModuleClasses
(
HMODULE16
hModule
);
extern
void
CLASS_FreeModuleClasses
(
HMODULE16
hModule
);
#endif
/* __WINE_WINPROC_H */
#endif
/* __WINE_WINPROC_H */
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