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
3172d351
Commit
3172d351
authored
Aug 19, 2013
by
Jacek Caban
Committed by
Alexandre Julliard
Aug 19, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Added IDispatchEx support to HTMLStyleSheet object.
parent
4f94913e
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
29 additions
and
9 deletions
+29
-9
htmlstylesheet.c
dlls/mshtml/htmlstylesheet.c
+25
-9
mshtml_private.h
dlls/mshtml/mshtml_private.h
+2
-0
dom.c
dlls/mshtml/tests/dom.c
+2
-0
No files found.
dlls/mshtml/htmlstylesheet.c
View file @
3172d351
...
@@ -32,6 +32,7 @@
...
@@ -32,6 +32,7 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
mshtml
);
WINE_DEFAULT_DEBUG_CHANNEL
(
mshtml
);
struct
HTMLStyleSheet
{
struct
HTMLStyleSheet
{
DispatchEx
dispex
;
IHTMLStyleSheet
IHTMLStyleSheet_iface
;
IHTMLStyleSheet
IHTMLStyleSheet_iface
;
LONG
ref
;
LONG
ref
;
...
@@ -412,6 +413,8 @@ static HRESULT WINAPI HTMLStyleSheet_QueryInterface(IHTMLStyleSheet *iface, REFI
...
@@ -412,6 +413,8 @@ static HRESULT WINAPI HTMLStyleSheet_QueryInterface(IHTMLStyleSheet *iface, REFI
}
else
if
(
IsEqualGUID
(
&
IID_IHTMLStyleSheet
,
riid
))
{
}
else
if
(
IsEqualGUID
(
&
IID_IHTMLStyleSheet
,
riid
))
{
TRACE
(
"(%p)->(IID_IHTMLStyleSheet %p)
\n
"
,
This
,
ppv
);
TRACE
(
"(%p)->(IID_IHTMLStyleSheet %p)
\n
"
,
This
,
ppv
);
*
ppv
=
&
This
->
IHTMLStyleSheet_iface
;
*
ppv
=
&
This
->
IHTMLStyleSheet_iface
;
}
else
if
(
dispex_query_interface
(
&
This
->
dispex
,
riid
,
ppv
))
{
return
*
ppv
?
S_OK
:
E_NOINTERFACE
;
}
}
if
(
*
ppv
)
{
if
(
*
ppv
)
{
...
@@ -449,16 +452,16 @@ static ULONG WINAPI HTMLStyleSheet_Release(IHTMLStyleSheet *iface)
...
@@ -449,16 +452,16 @@ static ULONG WINAPI HTMLStyleSheet_Release(IHTMLStyleSheet *iface)
static
HRESULT
WINAPI
HTMLStyleSheet_GetTypeInfoCount
(
IHTMLStyleSheet
*
iface
,
UINT
*
pctinfo
)
static
HRESULT
WINAPI
HTMLStyleSheet_GetTypeInfoCount
(
IHTMLStyleSheet
*
iface
,
UINT
*
pctinfo
)
{
{
HTMLStyleSheet
*
This
=
impl_from_IHTMLStyleSheet
(
iface
);
HTMLStyleSheet
*
This
=
impl_from_IHTMLStyleSheet
(
iface
);
FIXM
E
(
"(%p)->(%p)
\n
"
,
This
,
pctinfo
);
TRAC
E
(
"(%p)->(%p)
\n
"
,
This
,
pctinfo
);
return
E_NOTIMPL
;
return
IDispatchEx_GetTypeInfoCount
(
&
This
->
dispex
.
IDispatchEx_iface
,
pctinfo
)
;
}
}
static
HRESULT
WINAPI
HTMLStyleSheet_GetTypeInfo
(
IHTMLStyleSheet
*
iface
,
UINT
iTInfo
,
static
HRESULT
WINAPI
HTMLStyleSheet_GetTypeInfo
(
IHTMLStyleSheet
*
iface
,
UINT
iTInfo
,
LCID
lcid
,
ITypeInfo
**
ppTInfo
)
LCID
lcid
,
ITypeInfo
**
ppTInfo
)
{
{
HTMLStyleSheet
*
This
=
impl_from_IHTMLStyleSheet
(
iface
);
HTMLStyleSheet
*
This
=
impl_from_IHTMLStyleSheet
(
iface
);
FIXM
E
(
"(%p)->(%u %u %p)
\n
"
,
This
,
iTInfo
,
lcid
,
ppTInfo
);
TRAC
E
(
"(%p)->(%u %u %p)
\n
"
,
This
,
iTInfo
,
lcid
,
ppTInfo
);
return
E_NOTIMPL
;
return
IDispatchEx_GetTypeInfo
(
&
This
->
dispex
.
IDispatchEx_iface
,
iTInfo
,
lcid
,
ppTInfo
)
;
}
}
static
HRESULT
WINAPI
HTMLStyleSheet_GetIDsOfNames
(
IHTMLStyleSheet
*
iface
,
REFIID
riid
,
static
HRESULT
WINAPI
HTMLStyleSheet_GetIDsOfNames
(
IHTMLStyleSheet
*
iface
,
REFIID
riid
,
...
@@ -466,9 +469,8 @@ static HRESULT WINAPI HTMLStyleSheet_GetIDsOfNames(IHTMLStyleSheet *iface, REFII
...
@@ -466,9 +469,8 @@ static HRESULT WINAPI HTMLStyleSheet_GetIDsOfNames(IHTMLStyleSheet *iface, REFII
LCID
lcid
,
DISPID
*
rgDispId
)
LCID
lcid
,
DISPID
*
rgDispId
)
{
{
HTMLStyleSheet
*
This
=
impl_from_IHTMLStyleSheet
(
iface
);
HTMLStyleSheet
*
This
=
impl_from_IHTMLStyleSheet
(
iface
);
FIXME
(
"(%p)->(%s %p %u %u %p)
\n
"
,
This
,
debugstr_guid
(
riid
),
rgszNames
,
cNames
,
TRACE
(
"(%p)->(%s %p %u %u %p)
\n
"
,
This
,
debugstr_guid
(
riid
),
rgszNames
,
cNames
,
lcid
,
rgDispId
);
lcid
,
rgDispId
);
return
IDispatchEx_GetIDsOfNames
(
&
This
->
dispex
.
IDispatchEx_iface
,
riid
,
rgszNames
,
cNames
,
lcid
,
rgDispId
);
return
E_NOTIMPL
;
}
}
static
HRESULT
WINAPI
HTMLStyleSheet_Invoke
(
IHTMLStyleSheet
*
iface
,
DISPID
dispIdMember
,
static
HRESULT
WINAPI
HTMLStyleSheet_Invoke
(
IHTMLStyleSheet
*
iface
,
DISPID
dispIdMember
,
...
@@ -476,9 +478,10 @@ static HRESULT WINAPI HTMLStyleSheet_Invoke(IHTMLStyleSheet *iface, DISPID dispI
...
@@ -476,9 +478,10 @@ static HRESULT WINAPI HTMLStyleSheet_Invoke(IHTMLStyleSheet *iface, DISPID dispI
VARIANT
*
pVarResult
,
EXCEPINFO
*
pExcepInfo
,
UINT
*
puArgErr
)
VARIANT
*
pVarResult
,
EXCEPINFO
*
pExcepInfo
,
UINT
*
puArgErr
)
{
{
HTMLStyleSheet
*
This
=
impl_from_IHTMLStyleSheet
(
iface
);
HTMLStyleSheet
*
This
=
impl_from_IHTMLStyleSheet
(
iface
);
FIXM
E
(
"(%p)->(%d %s %d %d %p %p %p %p)
\n
"
,
This
,
dispIdMember
,
debugstr_guid
(
riid
),
TRAC
E
(
"(%p)->(%d %s %d %d %p %p %p %p)
\n
"
,
This
,
dispIdMember
,
debugstr_guid
(
riid
),
lcid
,
wFlags
,
pDispParams
,
pVarResult
,
pExcepInfo
,
puArgErr
);
lcid
,
wFlags
,
pDispParams
,
pVarResult
,
pExcepInfo
,
puArgErr
);
return
E_NOTIMPL
;
return
IDispatchEx_Invoke
(
&
This
->
dispex
.
IDispatchEx_iface
,
dispIdMember
,
riid
,
lcid
,
wFlags
,
pDispParams
,
pVarResult
,
pExcepInfo
,
puArgErr
);
}
}
static
HRESULT
WINAPI
HTMLStyleSheet_put_title
(
IHTMLStyleSheet
*
iface
,
BSTR
v
)
static
HRESULT
WINAPI
HTMLStyleSheet_put_title
(
IHTMLStyleSheet
*
iface
,
BSTR
v
)
...
@@ -676,6 +679,17 @@ static const IHTMLStyleSheetVtbl HTMLStyleSheetVtbl = {
...
@@ -676,6 +679,17 @@ static const IHTMLStyleSheetVtbl HTMLStyleSheetVtbl = {
HTMLStyleSheet_get_rules
HTMLStyleSheet_get_rules
};
};
static
const
tid_t
HTMLStyleSheet_iface_tids
[]
=
{
IHTMLStyleSheet_tid
,
0
};
static
dispex_static_data_t
HTMLStyleSheet_dispex
=
{
NULL
,
DispHTMLStyleSheet_tid
,
NULL
,
HTMLStyleSheet_iface_tids
};
IHTMLStyleSheet
*
HTMLStyleSheet_Create
(
nsIDOMStyleSheet
*
nsstylesheet
)
IHTMLStyleSheet
*
HTMLStyleSheet_Create
(
nsIDOMStyleSheet
*
nsstylesheet
)
{
{
HTMLStyleSheet
*
ret
=
heap_alloc
(
sizeof
(
HTMLStyleSheet
));
HTMLStyleSheet
*
ret
=
heap_alloc
(
sizeof
(
HTMLStyleSheet
));
...
@@ -685,6 +699,8 @@ IHTMLStyleSheet *HTMLStyleSheet_Create(nsIDOMStyleSheet *nsstylesheet)
...
@@ -685,6 +699,8 @@ IHTMLStyleSheet *HTMLStyleSheet_Create(nsIDOMStyleSheet *nsstylesheet)
ret
->
ref
=
1
;
ret
->
ref
=
1
;
ret
->
nsstylesheet
=
NULL
;
ret
->
nsstylesheet
=
NULL
;
init_dispex
(
&
ret
->
dispex
,
(
IUnknown
*
)
&
ret
->
IHTMLStyleSheet_iface
,
&
HTMLStyleSheet_dispex
);
if
(
nsstylesheet
)
{
if
(
nsstylesheet
)
{
nsres
=
nsIDOMStyleSheet_QueryInterface
(
nsstylesheet
,
&
IID_nsIDOMCSSStyleSheet
,
nsres
=
nsIDOMStyleSheet_QueryInterface
(
nsstylesheet
,
&
IID_nsIDOMCSSStyleSheet
,
(
void
**
)
&
ret
->
nsstylesheet
);
(
void
**
)
&
ret
->
nsstylesheet
);
...
...
dlls/mshtml/mshtml_private.h
View file @
3172d351
...
@@ -106,6 +106,7 @@ typedef struct event_target_t event_target_t;
...
@@ -106,6 +106,7 @@ typedef struct event_target_t event_target_t;
XDIID(DispHTMLSelectElement) \
XDIID(DispHTMLSelectElement) \
XDIID(DispHTMLStyle) \
XDIID(DispHTMLStyle) \
XDIID(DispHTMLStyleElement) \
XDIID(DispHTMLStyleElement) \
XDIID(DispHTMLStyleSheet) \
XDIID(DispHTMLStyleSheetsCollection) \
XDIID(DispHTMLStyleSheetsCollection) \
XDIID(DispHTMLTable) \
XDIID(DispHTMLTable) \
XDIID(DispHTMLTableCell) \
XDIID(DispHTMLTableCell) \
...
@@ -178,6 +179,7 @@ typedef struct event_target_t event_target_t;
...
@@ -178,6 +179,7 @@ typedef struct event_target_t event_target_t;
XIID(IHTMLStyle5) \
XIID(IHTMLStyle5) \
XIID(IHTMLStyle6) \
XIID(IHTMLStyle6) \
XIID(IHTMLStyleElement) \
XIID(IHTMLStyleElement) \
XIID(IHTMLStyleSheet) \
XIID(IHTMLStyleSheetsCollection) \
XIID(IHTMLStyleSheetsCollection) \
XIID(IHTMLTable) \
XIID(IHTMLTable) \
XIID(IHTMLTable2) \
XIID(IHTMLTable2) \
...
...
dlls/mshtml/tests/dom.c
View file @
3172d351
...
@@ -5839,6 +5839,8 @@ static void test_stylesheet(IDispatch *disp)
...
@@ -5839,6 +5839,8 @@ static void test_stylesheet(IDispatch *disp)
IHTMLStyleSheet
*
stylesheet
;
IHTMLStyleSheet
*
stylesheet
;
HRESULT
hres
;
HRESULT
hres
;
test_disp2
((
IUnknown
*
)
disp
,
&
DIID_DispHTMLStyleSheet
,
&
IID_IHTMLStyleSheet
,
"[object]"
);
hres
=
IDispatch_QueryInterface
(
disp
,
&
IID_IHTMLStyleSheet
,
(
void
**
)
&
stylesheet
);
hres
=
IDispatch_QueryInterface
(
disp
,
&
IID_IHTMLStyleSheet
,
(
void
**
)
&
stylesheet
);
ok
(
hres
==
S_OK
,
"Could not get IHTMLStyleSheet: %08x
\n
"
,
hres
);
ok
(
hres
==
S_OK
,
"Could not get IHTMLStyleSheet: %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