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
2330d73f
Commit
2330d73f
authored
Jan 31, 2006
by
Robert Shearman
Committed by
Alexandre Julliard
Jan 31, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
widl: Implement the writing of defaultvalue constants for enum values.
parent
fc6febc8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
2 deletions
+12
-2
write_msft.c
tools/widl/write_msft.c
+12
-2
No files found.
tools/widl/write_msft.c
View file @
2330d73f
...
@@ -1362,18 +1362,28 @@ static HRESULT add_func_desc(msft_typeinfo_t* typeinfo, func_t *func, int index)
...
@@ -1362,18 +1362,28 @@ static HRESULT add_func_desc(msft_typeinfo_t* typeinfo, func_t *func, int index)
switch
(
attr
->
type
)
{
switch
(
attr
->
type
)
{
case
ATTR_DEFAULTVALUE_EXPR
:
case
ATTR_DEFAULTVALUE_EXPR
:
{
{
int
vt
;
expr_t
*
expr
=
(
expr_t
*
)
attr
->
u
.
pval
;
expr_t
*
expr
=
(
expr_t
*
)
attr
->
u
.
pval
;
if
(
arg
->
type
->
type
==
RPC_FC_ENUM16
)
vt
=
VT_INT
;
else
vt
=
get_var_vt
(
arg
);
paramflags
|=
0x30
;
/* PARAMFLAG_FHASDEFAULT | PARAMFLAG_FOPT */
paramflags
|=
0x30
;
/* PARAMFLAG_FHASDEFAULT | PARAMFLAG_FOPT */
chat
(
"default value %ld
\n
"
,
expr
->
cval
);
chat
(
"default value %ld
\n
"
,
expr
->
cval
);
write_value
(
typeinfo
->
typelib
,
defaultdata
,
(
*
paramdata
>>
16
)
&
0x1ff
,
&
expr
->
cval
);
write_value
(
typeinfo
->
typelib
,
defaultdata
,
vt
,
&
expr
->
cval
);
break
;
break
;
}
}
case
ATTR_DEFAULTVALUE_STRING
:
case
ATTR_DEFAULTVALUE_STRING
:
{
{
char
*
s
=
(
char
*
)
attr
->
u
.
pval
;
char
*
s
=
(
char
*
)
attr
->
u
.
pval
;
int
vt
;
if
(
arg
->
type
->
type
==
RPC_FC_ENUM16
)
vt
=
VT_INT
;
else
vt
=
get_var_vt
(
arg
);
paramflags
|=
0x30
;
/* PARAMFLAG_FHASDEFAULT | PARAMFLAG_FOPT */
paramflags
|=
0x30
;
/* PARAMFLAG_FHASDEFAULT | PARAMFLAG_FOPT */
chat
(
"default value '%s'
\n
"
,
s
);
chat
(
"default value '%s'
\n
"
,
s
);
write_value
(
typeinfo
->
typelib
,
defaultdata
,
(
*
paramdata
>>
16
)
&
0x1ff
,
s
);
write_value
(
typeinfo
->
typelib
,
defaultdata
,
vt
,
s
);
break
;
break
;
}
}
case
ATTR_IN
:
case
ATTR_IN
:
...
...
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