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
cd345c10
Commit
cd345c10
authored
Oct 09, 2008
by
Jacek Caban
Committed by
Alexandre Julliard
Oct 10, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Forward IHTMLelement3::[get|put]_disabled to child object if possible.
parent
27eb80cc
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
105 additions
and
7 deletions
+105
-7
htmlelem3.c
dlls/mshtml/htmlelem3.c
+14
-3
htmlinput.c
dlls/mshtml/htmlinput.c
+15
-1
htmlselect.c
dlls/mshtml/htmlselect.c
+15
-1
htmltextarea.c
dlls/mshtml/htmltextarea.c
+15
-1
mshtml_private.h
dlls/mshtml/mshtml_private.h
+2
-0
dom.c
dlls/mshtml/tests/dom.c
+44
-1
No files found.
dlls/mshtml/htmlelem3.c
View file @
cd345c10
...
...
@@ -205,15 +205,26 @@ static HRESULT WINAPI HTMLElement3_get_hideFocus(IHTMLElement3 *iface, VARIANT_B
static
HRESULT
WINAPI
HTMLElement3_put_disabled
(
IHTMLElement3
*
iface
,
VARIANT_BOOL
v
)
{
HTMLElement
*
This
=
HTMLELEM3_THIS
(
iface
);
FIXME
(
"(%p)->(%x)
\n
"
,
This
,
v
);
return
S_OK
;
TRACE
(
"(%p)->(%x)
\n
"
,
This
,
v
);
if
(
This
->
node
.
vtbl
->
put_disabled
)
return
This
->
node
.
vtbl
->
put_disabled
(
&
This
->
node
,
v
);
FIXME
(
"No implementation for element
\n
"
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
HTMLElement3_get_disabled
(
IHTMLElement3
*
iface
,
VARIANT_BOOL
*
p
)
{
HTMLElement
*
This
=
HTMLELEM3_THIS
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
p
);
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
p
);
if
(
This
->
node
.
vtbl
->
get_disabled
)
return
This
->
node
.
vtbl
->
get_disabled
(
&
This
->
node
,
p
);
FIXME
(
"No implementation for element
\n
"
);
return
E_NOTIMPL
;
}
...
...
dlls/mshtml/htmlinput.c
View file @
cd345c10
...
...
@@ -1064,11 +1064,25 @@ static void HTMLInputElement_destructor(HTMLDOMNode *iface)
HTMLElement_destructor
(
&
This
->
element
.
node
);
}
static
HRESULT
HTMLInputElementImpl_put_disabled
(
HTMLDOMNode
*
iface
,
VARIANT_BOOL
v
)
{
HTMLInputElement
*
This
=
HTMLINPUT_NODE_THIS
(
iface
);
return
IHTMLInputElement_put_disabled
(
HTMLINPUT
(
This
),
v
);
}
static
HRESULT
HTMLInputElementImpl_get_disabled
(
HTMLDOMNode
*
iface
,
VARIANT_BOOL
*
p
)
{
HTMLInputElement
*
This
=
HTMLINPUT_NODE_THIS
(
iface
);
return
IHTMLInputElement_get_disabled
(
HTMLINPUT
(
This
),
p
);
}
#undef HTMLINPUT_NODE_THIS
static
const
NodeImplVtbl
HTMLInputElementImplVtbl
=
{
HTMLInputElement_QI
,
HTMLInputElement_destructor
HTMLInputElement_destructor
,
HTMLInputElementImpl_put_disabled
,
HTMLInputElementImpl_get_disabled
,
};
static
const
tid_t
HTMLInputElement_iface_tids
[]
=
{
...
...
dlls/mshtml/htmlselect.c
View file @
cd345c10
...
...
@@ -442,11 +442,25 @@ static void HTMLSelectElement_destructor(HTMLDOMNode *iface)
HTMLElement_destructor
(
&
This
->
element
.
node
);
}
static
HRESULT
HTMLSelectElementImpl_put_disabled
(
HTMLDOMNode
*
iface
,
VARIANT_BOOL
v
)
{
HTMLSelectElement
*
This
=
HTMLSELECT_NODE_THIS
(
iface
);
return
IHTMLSelectElement_put_disabled
(
HTMLSELECT
(
This
),
v
);
}
static
HRESULT
HTMLSelectElementImpl_get_disabled
(
HTMLDOMNode
*
iface
,
VARIANT_BOOL
*
p
)
{
HTMLSelectElement
*
This
=
HTMLSELECT_NODE_THIS
(
iface
);
return
IHTMLSelectElement_get_disabled
(
HTMLSELECT
(
This
),
p
);
}
#undef HTMLSELECT_NODE_THIS
static
const
NodeImplVtbl
HTMLSelectElementImplVtbl
=
{
HTMLSelectElement_QI
,
HTMLSelectElement_destructor
HTMLSelectElement_destructor
,
HTMLSelectElementImpl_put_disabled
,
HTMLSelectElementImpl_get_disabled
};
static
const
tid_t
HTMLSelectElement_tids
[]
=
{
...
...
dlls/mshtml/htmltextarea.c
View file @
cd345c10
...
...
@@ -388,11 +388,25 @@ static void HTMLTextAreaElement_destructor(HTMLDOMNode *iface)
HTMLElement_destructor
(
&
This
->
element
.
node
);
}
static
HRESULT
HTMLTextAreaElementImpl_put_disabled
(
HTMLDOMNode
*
iface
,
VARIANT_BOOL
v
)
{
HTMLTextAreaElement
*
This
=
HTMLTXTAREA_NODE_THIS
(
iface
);
return
IHTMLTextAreaElement_put_disabled
(
HTMLTXTAREA
(
This
),
v
);
}
static
HRESULT
HTMLTextAreaElementImpl_get_disabled
(
HTMLDOMNode
*
iface
,
VARIANT_BOOL
*
p
)
{
HTMLTextAreaElement
*
This
=
HTMLTXTAREA_NODE_THIS
(
iface
);
return
IHTMLTextAreaElement_get_disabled
(
HTMLTXTAREA
(
This
),
p
);
}
#undef HTMLTXTAREA_NODE_THIS
static
const
NodeImplVtbl
HTMLTextAreaElementImplVtbl
=
{
HTMLTextAreaElement_QI
,
HTMLTextAreaElement_destructor
HTMLTextAreaElement_destructor
,
HTMLTextAreaElementImpl_put_disabled
,
HTMLTextAreaElementImpl_get_disabled
};
HTMLElement
*
HTMLTextAreaElement_Create
(
nsIDOMHTMLElement
*
nselem
)
...
...
dlls/mshtml/mshtml_private.h
View file @
cd345c10
...
...
@@ -361,6 +361,8 @@ typedef struct {
typedef
struct
{
HRESULT
(
*
qi
)(
HTMLDOMNode
*
,
REFIID
,
void
**
);
void
(
*
destructor
)(
HTMLDOMNode
*
);
HRESULT
(
*
put_disabled
)(
HTMLDOMNode
*
,
VARIANT_BOOL
);
HRESULT
(
*
get_disabled
)(
HTMLDOMNode
*
,
VARIANT_BOOL
*
);
}
NodeImplVtbl
;
struct
HTMLDOMNode
{
...
...
dlls/mshtml/tests/dom.c
View file @
cd345c10
/*
* Copyright 2007 Jacek Caban for CodeWeavers
* Copyright 2007
-2008
Jacek Caban for CodeWeavers
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
...
...
@@ -471,6 +471,17 @@ static IHTMLElement2 *_get_elem2_iface(unsigned line, IUnknown *unk)
return
elem
;
}
#define get_elem3_iface(u) _get_elem3_iface(__LINE__,u)
static
IHTMLElement3
*
_get_elem3_iface
(
unsigned
line
,
IUnknown
*
unk
)
{
IHTMLElement3
*
elem
;
HRESULT
hres
;
hres
=
IUnknown_QueryInterface
(
unk
,
&
IID_IHTMLElement3
,
(
void
**
)
&
elem
);
ok_
(
__FILE__
,
line
)
(
hres
==
S_OK
,
"Coule not get IHTMLElement3: %08x
\n
"
,
hres
);
return
elem
;
}
#define get_node_iface(u) _get_node_iface(__LINE__,u)
static
IHTMLDOMNode
*
_get_node_iface
(
unsigned
line
,
IUnknown
*
unk
)
{
...
...
@@ -1059,6 +1070,32 @@ static IHTMLElement *_test_elem_get_parent(unsigned line, IUnknown *unk)
return
parent
;
}
#define test_elem3_get_disabled(i,b) _test_elem3_get_disabled(__LINE__,i,b)
static
void
_test_elem3_get_disabled
(
unsigned
line
,
IUnknown
*
unk
,
VARIANT_BOOL
exb
)
{
IHTMLElement3
*
elem3
=
_get_elem3_iface
(
line
,
unk
);
VARIANT_BOOL
disabled
=
100
;
HRESULT
hres
;
hres
=
IHTMLElement3_get_disabled
(
elem3
,
&
disabled
);
ok_
(
__FILE__
,
line
)
(
hres
==
S_OK
,
"get_disabled failed: %08x
\n
"
,
hres
);
ok_
(
__FILE__
,
line
)
(
disabled
==
exb
,
"disabled=%x, expected %x
\n
"
,
disabled
,
exb
);
IHTMLElement3_Release
(
elem3
);
}
#define test_elem3_set_disabled(i,b) _test_elem3_set_disabled(__LINE__,i,b)
static
void
_test_elem3_set_disabled
(
unsigned
line
,
IUnknown
*
unk
,
VARIANT_BOOL
b
)
{
IHTMLElement3
*
elem3
=
_get_elem3_iface
(
line
,
unk
);
HRESULT
hres
;
hres
=
IHTMLElement3_put_disabled
(
elem3
,
b
);
ok_
(
__FILE__
,
line
)
(
hres
==
S_OK
,
"get_disabled failed: %08x
\n
"
,
hres
);
IHTMLElement3_Release
(
elem3
);
_test_elem3_get_disabled
(
line
,
unk
,
b
);
}
#define elem_get_scroll_height(u) _elem_get_scroll_height(__LINE__,u)
static
long
_elem_get_scroll_height
(
unsigned
line
,
IUnknown
*
unk
)
{
...
...
@@ -1206,6 +1243,8 @@ static void _test_input_get_disabled(unsigned line, IHTMLInputElement *input, VA
hres
=
IHTMLInputElement_get_disabled
(
input
,
&
disabled
);
ok_
(
__FILE__
,
line
)
(
hres
==
S_OK
,
"get_disabled failed: %08x
\n
"
,
hres
);
ok_
(
__FILE__
,
line
)
(
disabled
==
exb
,
"disabled=%x, expected %x
\n
"
,
disabled
,
exb
);
_test_elem3_get_disabled
(
line
,
(
IUnknown
*
)
input
,
exb
);
}
#define test_input_set_disabled(i,b) _test_input_set_disabled(__LINE__,i,b)
...
...
@@ -2838,6 +2877,10 @@ static void test_elems(IHTMLDocument2 *doc)
test_input_get_disabled
(
input
,
VARIANT_FALSE
);
test_input_set_disabled
(
input
,
VARIANT_TRUE
);
test_input_set_disabled
(
input
,
VARIANT_FALSE
);
test_elem3_set_disabled
((
IUnknown
*
)
input
,
VARIANT_TRUE
);
test_input_get_disabled
(
input
,
VARIANT_TRUE
);
test_elem3_set_disabled
((
IUnknown
*
)
input
,
VARIANT_FALSE
);
test_input_get_disabled
(
input
,
VARIANT_FALSE
);
test_elem_client_size
((
IUnknown
*
)
elem
);
test_node_get_value_str
((
IUnknown
*
)
elem
,
NULL
);
...
...
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