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
835b814e
Commit
835b814e
authored
Sep 15, 2007
by
Jacek Caban
Committed by
Alexandre Julliard
Sep 17, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Store HTMLElement struct instead of pointer in HTMLSelectElement.
parent
8a8af7b4
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
13 deletions
+15
-13
htmlelem.c
dlls/mshtml/htmlelem.c
+3
-3
htmlselect.c
dlls/mshtml/htmlselect.c
+11
-9
mshtml_private.h
dlls/mshtml/mshtml_private.h
+1
-1
No files found.
dlls/mshtml/htmlelem.c
View file @
835b814e
...
...
@@ -1300,6 +1300,8 @@ HTMLElement *HTMLElement_Create(nsIDOMNode *nsnode)
ret
=
HTMLBodyElement_Create
(
nselem
);
else
if
(
!
strcmpW
(
class_name
,
wszINPUT
))
ret
=
HTMLInputElement_Create
(
nselem
);
if
(
!
strcmpW
(
class_name
,
wszSELECT
))
ret
=
HTMLSelectElement_Create
(
nselem
);
else
{
ret
=
mshtml_alloc
(
sizeof
(
HTMLElement
));
...
...
@@ -1307,9 +1309,7 @@ HTMLElement *HTMLElement_Create(nsIDOMNode *nsnode)
ret
->
destructor
=
NULL
;
ret
->
nselem
=
nselem
;
if
(
!
strcmpW
(
class_name
,
wszSELECT
))
HTMLSelectElement_Create
(
ret
);
else
if
(
!
strcmpW
(
class_name
,
wszTEXTAREA
))
if
(
!
strcmpW
(
class_name
,
wszTEXTAREA
))
HTMLTextAreaElement_Create
(
ret
);
}
...
...
dlls/mshtml/htmlselect.c
View file @
835b814e
...
...
@@ -36,9 +36,10 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
mshtml
);
typedef
struct
{
HTMLElement
element
;
const
IHTMLSelectElementVtbl
*
lpHTMLSelectElementVtbl
;
HTMLElement
*
element
;
nsIDOMHTMLSelectElement
*
nsselect
;
}
HTMLSelectElement
;
...
...
@@ -70,7 +71,7 @@ static HRESULT WINAPI HTMLSelectElement_QueryInterface(IHTMLSelectElement *iface
return
S_OK
;
}
hres
=
HTMLElement_QI
(
This
->
element
,
riid
,
ppv
);
hres
=
HTMLElement_QI
(
&
This
->
element
,
riid
,
ppv
);
if
(
FAILED
(
hres
))
WARN
(
"(%p)->(%s %p)
\n
"
,
This
,
debugstr_guid
(
riid
),
ppv
);
...
...
@@ -83,7 +84,7 @@ static ULONG WINAPI HTMLSelectElement_AddRef(IHTMLSelectElement *iface)
TRACE
(
"(%p)
\n
"
,
This
);
return
IHTMLDocument2_AddRef
(
HTMLDOC
(
This
->
element
->
node
.
doc
));
return
IHTMLDocument2_AddRef
(
HTMLDOC
(
This
->
element
.
node
.
doc
));
}
static
ULONG
WINAPI
HTMLSelectElement_Release
(
IHTMLSelectElement
*
iface
)
...
...
@@ -92,7 +93,7 @@ static ULONG WINAPI HTMLSelectElement_Release(IHTMLSelectElement *iface)
TRACE
(
"(%p)
\n
"
,
This
);
return
IHTMLDocument2_Release
(
HTMLDOC
(
This
->
element
->
node
.
doc
));
return
IHTMLDocument2_Release
(
HTMLDOC
(
This
->
element
.
node
.
doc
));
}
static
HRESULT
WINAPI
HTMLSelectElement_GetTypeInfoCount
(
IHTMLSelectElement
*
iface
,
UINT
*
pctinfo
)
...
...
@@ -386,19 +387,20 @@ static const IHTMLSelectElementVtbl HTMLSelectElementVtbl = {
HTMLSelectElement_tags
};
void
HTMLSelectElement_Create
(
HTMLElement
*
element
)
HTMLElement
*
HTMLSelectElement_Create
(
nsIDOMHTMLElement
*
nselem
)
{
HTMLSelectElement
*
ret
=
mshtml_alloc
(
sizeof
(
HTMLSelectElement
));
nsresult
nsres
;
ret
->
lpHTMLSelectElementVtbl
=
&
HTMLSelectElementVtbl
;
ret
->
element
=
element
;
nsres
=
nsIDOMHTMLElement_QueryInterface
(
element
->
nselem
,
&
IID_nsIDOMHTMLSelectElement
,
nsres
=
nsIDOMHTMLElement_QueryInterface
(
nselem
,
&
IID_nsIDOMHTMLSelectElement
,
(
void
**
)
&
ret
->
nsselect
);
if
(
NS_FAILED
(
nsres
))
ERR
(
"Could not get nsIDOMHTMLSelectElement interfce: %08x
\n
"
,
nsres
);
element
->
impl
=
(
IUnknown
*
)
HTMLSELECT
(
ret
);
element
->
destructor
=
HTMLSelectElement_destructor
;
ret
->
element
.
impl
=
(
IUnknown
*
)
HTMLSELECT
(
ret
);
ret
->
element
.
destructor
=
HTMLSelectElement_destructor
;
return
&
ret
->
element
;
}
dlls/mshtml/mshtml_private.h
View file @
835b814e
...
...
@@ -419,7 +419,7 @@ HTMLElement *HTMLElement_Create(nsIDOMNode*);
HTMLElement
*
HTMLAnchorElement_Create
(
nsIDOMHTMLElement
*
);
HTMLElement
*
HTMLBodyElement_Create
(
nsIDOMHTMLElement
*
);
HTMLElement
*
HTMLInputElement_Create
(
nsIDOMHTMLElement
*
);
void
HTMLSelectElement_Create
(
HTMLElement
*
);
HTMLElement
*
HTMLSelectElement_Create
(
nsIDOM
HTMLElement
*
);
void
HTMLTextAreaElement_Create
(
HTMLElement
*
);
void
HTMLElement2_Init
(
HTMLElement
*
);
...
...
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