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
042fbbc5
Commit
042fbbc5
authored
Sep 06, 2018
by
Jacek Caban
Committed by
Alexandre Julliard
Sep 06, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Added IHTMLCSSStyleDeclaration::opacity property implementation.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
6ebfbcc6
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
42 additions
and
4 deletions
+42
-4
htmlstyle.c
dlls/mshtml/htmlstyle.c
+7
-4
htmlstyle.h
dlls/mshtml/htmlstyle.h
+1
-0
style.c
dlls/mshtml/tests/style.c
+34
-0
No files found.
dlls/mshtml/htmlstyle.c
View file @
042fbbc5
...
...
@@ -156,6 +156,8 @@ static const WCHAR min_heightW[] =
{
'm'
,
'i'
,
'n'
,
'-'
,
'h'
,
'e'
,
'i'
,
'g'
,
'h'
,
't'
,
0
};
static
const
WCHAR
min_widthW
[]
=
{
'm'
,
'i'
,
'n'
,
'-'
,
'w'
,
'i'
,
'd'
,
't'
,
'h'
,
0
};
static
const
WCHAR
opacityW
[]
=
{
'o'
,
'p'
,
'a'
,
'c'
,
'i'
,
't'
,
'y'
,
0
};
static
const
WCHAR
outlineW
[]
=
{
'o'
,
'u'
,
't'
,
'l'
,
'i'
,
'n'
,
'e'
,
0
};
static
const
WCHAR
overflowW
[]
=
...
...
@@ -393,6 +395,7 @@ static const style_tbl_entry_t style_tbl[] = {
{
max_widthW
,
DISPID_IHTMLSTYLE5_MAXWIDTH
,
ATTR_FIX_PX
},
{
min_heightW
,
DISPID_IHTMLSTYLE4_MINHEIGHT
},
{
min_widthW
,
DISPID_IHTMLSTYLE5_MINWIDTH
,
ATTR_FIX_PX
},
{
opacityW
,
DISPID_UNKNOWN
},
{
outlineW
,
DISPID_IHTMLSTYLE6_OUTLINE
,
ATTR_NO_NULL
},
{
overflowW
,
DISPID_IHTMLSTYLE_OVERFLOW
,
0
,
overflow_values
},
{
overflow_xW
,
DISPID_IHTMLSTYLE2_OVERFLOWX
},
...
...
@@ -6796,15 +6799,15 @@ static HRESULT WINAPI HTMLCSSStyleDeclaration_get_fontStretch(IHTMLCSSStyleDecla
static
HRESULT
WINAPI
HTMLCSSStyleDeclaration_put_opacity
(
IHTMLCSSStyleDeclaration
*
iface
,
VARIANT
v
)
{
HTMLStyle
*
This
=
impl_from_IHTMLCSSStyleDeclaration
(
iface
);
FIXM
E
(
"(%p)->(%s)
\n
"
,
This
,
debugstr_variant
(
&
v
));
return
E_NOTIMPL
;
TRAC
E
(
"(%p)->(%s)
\n
"
,
This
,
debugstr_variant
(
&
v
));
return
set_style_property_var
(
This
,
STYLEID_OPACITY
,
&
v
)
;
}
static
HRESULT
WINAPI
HTMLCSSStyleDeclaration_get_opacity
(
IHTMLCSSStyleDeclaration
*
iface
,
VARIANT
*
p
)
{
HTMLStyle
*
This
=
impl_from_IHTMLCSSStyleDeclaration
(
iface
);
FIXM
E
(
"(%p)->(%p)
\n
"
,
This
,
p
);
return
E_NOTIMPL
;
TRAC
E
(
"(%p)->(%p)
\n
"
,
This
,
p
);
return
get_style_property_var
(
This
,
STYLEID_OPACITY
,
p
)
;
}
static
HRESULT
WINAPI
HTMLCSSStyleDeclaration_put_clipPath
(
IHTMLCSSStyleDeclaration
*
iface
,
BSTR
v
)
...
...
dlls/mshtml/htmlstyle.h
View file @
042fbbc5
...
...
@@ -94,6 +94,7 @@ typedef enum {
STYLEID_MAX_WIDTH
,
STYLEID_MIN_HEIGHT
,
STYLEID_MIN_WIDTH
,
STYLEID_OPACITY
,
STYLEID_OUTLINE
,
STYLEID_OVERFLOW
,
STYLEID_OVERFLOW_X
,
...
...
dlls/mshtml/tests/style.c
View file @
042fbbc5
...
...
@@ -738,6 +738,7 @@ static void test_style6(IHTMLStyle6 *style)
static
void
test_css_style_declaration
(
IHTMLCSSStyleDeclaration
*
css_style
)
{
VARIANT
v
;
BSTR
str
;
HRESULT
hres
;
...
...
@@ -754,6 +755,31 @@ static void test_css_style_declaration(IHTMLCSSStyleDeclaration *css_style)
ok
(
hres
==
S_OK
,
"get_backgroundClip failed: %08x
\n
"
,
hres
);
ok
(
!
strcmp_wa
(
str
,
"border-box"
),
"backgroundClip = %s
\n
"
,
wine_dbgstr_w
(
str
));
SysFreeString
(
str
);
hres
=
IHTMLCSSStyleDeclaration_get_opacity
(
css_style
,
&
v
);
ok
(
hres
==
S_OK
,
"get_opacity failed: %08x
\n
"
,
hres
);
test_var_bstr
(
&
v
,
NULL
);
V_VT
(
&
v
)
=
VT_I4
;
V_I4
(
&
v
)
=
0
;
hres
=
IHTMLCSSStyleDeclaration_put_opacity
(
css_style
,
v
);
ok
(
hres
==
S_OK
,
"put_opacity failed: %08x
\n
"
,
hres
);
hres
=
IHTMLCSSStyleDeclaration_get_opacity
(
css_style
,
&
v
);
ok
(
hres
==
S_OK
,
"get_opacity failed: %08x
\n
"
,
hres
);
test_var_bstr
(
&
v
,
"0"
);
VariantClear
(
&
v
);
V_VT
(
&
v
)
=
VT_BSTR
;
V_BSTR
(
&
v
)
=
a2bstr
(
"1"
);
hres
=
IHTMLCSSStyleDeclaration_put_opacity
(
css_style
,
v
);
ok
(
hres
==
S_OK
,
"put_opacity failed: %08x
\n
"
,
hres
);
VariantClear
(
&
v
);
hres
=
IHTMLCSSStyleDeclaration_get_opacity
(
css_style
,
&
v
);
ok
(
hres
==
S_OK
,
"get_opacity failed: %08x
\n
"
,
hres
);
test_var_bstr
(
&
v
,
"1"
);
VariantClear
(
&
v
);
}
static
void
test_body_style
(
IHTMLStyle
*
style
)
...
...
@@ -1790,6 +1816,14 @@ static void test_body_style(IHTMLStyle *style)
ok
(
hres
==
S_OK
,
"put_filter failed: %08x
\n
"
,
hres
);
SysFreeString
(
str
);
hres
=
IHTMLStyle_put_filter
(
style
,
NULL
);
ok
(
hres
==
S_OK
,
"put_filter failed: %08x
\n
"
,
hres
);
str
=
(
void
*
)
0xdeadbeef
;
hres
=
IHTMLStyle_get_filter
(
style
,
&
str
);
ok
(
hres
==
S_OK
,
"get_filter failed: %08x
\n
"
,
hres
);
ok
(
!
str
,
"filter != NULL
\n
"
);
V_VT
(
&
v
)
=
VT_EMPTY
;
hres
=
IHTMLStyle_get_zIndex
(
style
,
&
v
);
ok
(
hres
==
S_OK
,
"get_zIndex failed: %08x
\n
"
,
hres
);
...
...
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