Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
8d28f09d
Commit
8d28f09d
authored
Dec 30, 2008
by
Jacek Caban
Committed by
Alexandre Julliard
Dec 30, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Wine Gecko 0.9.0 release.
parent
03a83c49
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
137 additions
and
47 deletions
+137
-47
Makefile.in
dlls/mshtml/Makefile.in
+1
-0
htmlelem2.c
dlls/mshtml/htmlelem2.c
+39
-39
mshtml_private.h
dlls/mshtml/mshtml_private.h
+22
-0
mutation.c
dlls/mshtml/mutation.c
+0
-0
nsembed.c
dlls/mshtml/nsembed.c
+8
-3
nsevents.c
dlls/mshtml/nsevents.c
+1
-4
nsiface.idl
dlls/mshtml/nsiface.idl
+0
-0
nsio.c
dlls/mshtml/nsio.c
+66
-1
No files found.
dlls/mshtml/Makefile.in
View file @
8d28f09d
...
...
@@ -45,6 +45,7 @@ C_SRCS = \
install.c
\
loadopts.c
\
main.c
\
mutation.c
\
navigate.c
\
nsembed.c
\
nsevents.c
\
...
...
dlls/mshtml/htmlelem2.c
View file @
8d28f09d
...
...
@@ -548,18 +548,18 @@ static HRESULT WINAPI HTMLElement2_removeFilter(IHTMLElement2 *iface, IUnknown *
static
HRESULT
WINAPI
HTMLElement2_get_clientHeight
(
IHTMLElement2
*
iface
,
long
*
p
)
{
HTMLElement
*
This
=
HTMLELEM2_THIS
(
iface
);
nsIDOMNS
HTML
Element
*
nselem
;
nsIDOMNSElement
*
nselem
;
PRInt32
height
=
0
;
nsresult
nsres
;
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
p
);
nsres
=
nsIDOMHTMLElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNS
HTML
Element
,
(
void
**
)
&
nselem
);
nsres
=
nsIDOMHTMLElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNSElement
,
(
void
**
)
&
nselem
);
if
(
NS_SUCCEEDED
(
nsres
))
{
nsIDOMNS
HTML
Element_GetClientHeight
(
nselem
,
&
height
);
nsIDOMNS
HTML
Element_Release
(
nselem
);
nsIDOMNSElement_GetClientHeight
(
nselem
,
&
height
);
nsIDOMNSElement_Release
(
nselem
);
}
else
{
ERR
(
"Could not get nsIDOM
HTML
NSElement: %08x
\n
"
,
nsres
);
ERR
(
"Could not get nsIDOMNSElement: %08x
\n
"
,
nsres
);
}
*
p
=
height
;
...
...
@@ -569,18 +569,18 @@ static HRESULT WINAPI HTMLElement2_get_clientHeight(IHTMLElement2 *iface, long *
static
HRESULT
WINAPI
HTMLElement2_get_clientWidth
(
IHTMLElement2
*
iface
,
long
*
p
)
{
HTMLElement
*
This
=
HTMLELEM2_THIS
(
iface
);
nsIDOMNS
HTML
Element
*
nselem
;
nsIDOMNSElement
*
nselem
;
PRInt32
width
=
0
;
nsresult
nsres
;
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
p
);
nsres
=
nsIDOMHTMLElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNS
HTML
Element
,
(
void
**
)
&
nselem
);
nsres
=
nsIDOMHTMLElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNSElement
,
(
void
**
)
&
nselem
);
if
(
NS_SUCCEEDED
(
nsres
))
{
nsIDOMNS
HTML
Element_GetClientWidth
(
nselem
,
&
width
);
nsIDOMNS
HTML
Element_Release
(
nselem
);
nsIDOMNSElement_GetClientWidth
(
nselem
,
&
width
);
nsIDOMNSElement_Release
(
nselem
);
}
else
{
ERR
(
"Could not get nsIDOM
HTML
NSElement: %08x
\n
"
,
nsres
);
ERR
(
"Could not get nsIDOMNSElement: %08x
\n
"
,
nsres
);
}
*
p
=
width
;
...
...
@@ -727,7 +727,7 @@ static HRESULT WINAPI HTMLElement2_createControlRange(IHTMLElement2 *iface, IDis
static
HRESULT
WINAPI
HTMLElement2_get_scrollHeight
(
IHTMLElement2
*
iface
,
long
*
p
)
{
HTMLElement
*
This
=
HTMLELEM2_THIS
(
iface
);
nsIDOMNS
HTML
Element
*
nselem
;
nsIDOMNSElement
*
nselem
;
PRInt32
height
=
0
;
nsresult
nsres
;
...
...
@@ -735,15 +735,15 @@ static HRESULT WINAPI HTMLElement2_get_scrollHeight(IHTMLElement2 *iface, long *
nsres
=
nsIDOMElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNSHTMLElement
,
(
void
**
)
&
nselem
);
if
(
NS_SUCCEEDED
(
nsres
))
{
nsres
=
nsIDOMNS
HTML
Element_GetScrollHeight
(
nselem
,
&
height
);
nsIDOMNS
HTML
Element_Release
(
nselem
);
nsres
=
nsIDOMNSElement_GetScrollHeight
(
nselem
,
&
height
);
nsIDOMNSElement_Release
(
nselem
);
if
(
NS_FAILED
(
nsres
))
ERR
(
"GetScrollHeight failed: %08x
\n
"
,
nsres
);
}
else
{
ERR
(
"Could not get nsIDOMNS
HTML
Element interface: %08x
\n
"
,
nsres
);
ERR
(
"Could not get nsIDOMNSElement interface: %08x
\n
"
,
nsres
);
}
*
p
=
height
;
*
p
=
height
==
-
1
?
0
:
height
;
TRACE
(
"*p = %ld
\n
"
,
*
p
);
return
S_OK
;
...
...
@@ -752,20 +752,20 @@ static HRESULT WINAPI HTMLElement2_get_scrollHeight(IHTMLElement2 *iface, long *
static
HRESULT
WINAPI
HTMLElement2_get_scrollWidth
(
IHTMLElement2
*
iface
,
long
*
p
)
{
HTMLElement
*
This
=
HTMLELEM2_THIS
(
iface
);
nsIDOMNS
HTML
Element
*
nselem
;
nsIDOMNSElement
*
nselem
;
PRInt32
width
=
0
;
nsresult
nsres
;
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
p
);
nsres
=
nsIDOMElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNS
HTML
Element
,
(
void
**
)
&
nselem
);
nsres
=
nsIDOMElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNSElement
,
(
void
**
)
&
nselem
);
if
(
NS_SUCCEEDED
(
nsres
))
{
nsres
=
nsIDOMNS
HTML
Element_GetScrollWidth
(
nselem
,
&
width
);
nsIDOMNS
HTML
Element_Release
(
nselem
);
nsres
=
nsIDOMNSElement_GetScrollWidth
(
nselem
,
&
width
);
nsIDOMNSElement_Release
(
nselem
);
if
(
NS_FAILED
(
nsres
))
ERR
(
"GetScrollWidth failed: %08x
\n
"
,
nsres
);
}
else
{
ERR
(
"Could not get nsIDOMNS
HTML
Element interface: %08x
\n
"
,
nsres
);
ERR
(
"Could not get nsIDOMNSElement interface: %08x
\n
"
,
nsres
);
}
*
p
=
width
;
...
...
@@ -777,7 +777,7 @@ static HRESULT WINAPI HTMLElement2_get_scrollWidth(IHTMLElement2 *iface, long *p
static
HRESULT
WINAPI
HTMLElement2_put_scrollTop
(
IHTMLElement2
*
iface
,
long
v
)
{
HTMLElement
*
This
=
HTMLELEM2_THIS
(
iface
);
nsIDOMNS
HTML
Element
*
nselem
;
nsIDOMNSElement
*
nselem
;
nsresult
nsres
;
TRACE
(
"(%p)->(%ld)
\n
"
,
This
,
v
);
...
...
@@ -787,12 +787,12 @@ static HRESULT WINAPI HTMLElement2_put_scrollTop(IHTMLElement2 *iface, long v)
return
E_NOTIMPL
;
}
nsres
=
nsIDOMHTMLElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNS
HTML
Element
,
(
void
**
)
&
nselem
);
nsres
=
nsIDOMHTMLElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNSElement
,
(
void
**
)
&
nselem
);
if
(
NS_SUCCEEDED
(
nsres
))
{
nsIDOMNS
HTML
Element_SetScrollTop
(
nselem
,
v
);
nsIDOMNS
HTML
Element_Release
(
nselem
);
nsIDOMNSElement_SetScrollTop
(
nselem
,
v
);
nsIDOMNSElement_Release
(
nselem
);
}
else
{
ERR
(
"Could not get nsIDOMNS
HTML
Element interface: %08x
\n
"
,
nsres
);
ERR
(
"Could not get nsIDOMNSElement interface: %08x
\n
"
,
nsres
);
}
return
S_OK
;
...
...
@@ -801,20 +801,20 @@ static HRESULT WINAPI HTMLElement2_put_scrollTop(IHTMLElement2 *iface, long v)
static
HRESULT
WINAPI
HTMLElement2_get_scrollTop
(
IHTMLElement2
*
iface
,
long
*
p
)
{
HTMLElement
*
This
=
HTMLELEM2_THIS
(
iface
);
nsIDOMNS
HTML
Element
*
nselem
;
nsIDOMNSElement
*
nselem
;
PRInt32
top
=
0
;
nsresult
nsres
;
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
p
);
nsres
=
nsIDOMElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNS
HTML
Element
,
(
void
**
)
&
nselem
);
nsres
=
nsIDOMElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNSElement
,
(
void
**
)
&
nselem
);
if
(
NS_SUCCEEDED
(
nsres
))
{
nsres
=
nsIDOMNS
HTML
Element_GetScrollTop
(
nselem
,
&
top
);
nsIDOMNS
HTML
Element_Release
(
nselem
);
nsres
=
nsIDOMNSElement_GetScrollTop
(
nselem
,
&
top
);
nsIDOMNSElement_Release
(
nselem
);
if
(
NS_FAILED
(
nsres
))
ERR
(
"GetScrollTop failed: %08x
\n
"
,
nsres
);
}
else
{
ERR
(
"Could not get nsIDOMNS
HTML
Element interface: %08x
\n
"
,
nsres
);
ERR
(
"Could not get nsIDOMNSElement interface: %08x
\n
"
,
nsres
);
}
*
p
=
top
;
...
...
@@ -826,7 +826,7 @@ static HRESULT WINAPI HTMLElement2_get_scrollTop(IHTMLElement2 *iface, long *p)
static
HRESULT
WINAPI
HTMLElement2_put_scrollLeft
(
IHTMLElement2
*
iface
,
long
v
)
{
HTMLElement
*
This
=
HTMLELEM2_THIS
(
iface
);
nsIDOMNS
HTML
Element
*
nselem
;
nsIDOMNSElement
*
nselem
;
nsresult
nsres
;
TRACE
(
"(%p)->(%ld)
\n
"
,
This
,
v
);
...
...
@@ -836,12 +836,12 @@ static HRESULT WINAPI HTMLElement2_put_scrollLeft(IHTMLElement2 *iface, long v)
return
E_NOTIMPL
;
}
nsres
=
nsIDOM
HTMLElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNSHTML
Element
,
(
void
**
)
&
nselem
);
nsres
=
nsIDOM
Element_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNS
Element
,
(
void
**
)
&
nselem
);
if
(
NS_SUCCEEDED
(
nsres
))
{
nsIDOMNS
HTML
Element_SetScrollLeft
(
nselem
,
v
);
nsIDOMNS
HTML
Element_Release
(
nselem
);
nsIDOMNSElement_SetScrollLeft
(
nselem
,
v
);
nsIDOMNSElement_Release
(
nselem
);
}
else
{
ERR
(
"Could not get nsIDOMNS
HTML
Element interface: %08x
\n
"
,
nsres
);
ERR
(
"Could not get nsIDOMNSElement interface: %08x
\n
"
,
nsres
);
}
return
S_OK
;
...
...
@@ -850,7 +850,7 @@ static HRESULT WINAPI HTMLElement2_put_scrollLeft(IHTMLElement2 *iface, long v)
static
HRESULT
WINAPI
HTMLElement2_get_scrollLeft
(
IHTMLElement2
*
iface
,
long
*
p
)
{
HTMLElement
*
This
=
HTMLELEM2_THIS
(
iface
);
nsIDOMNS
HTML
Element
*
nselem
;
nsIDOMNSElement
*
nselem
;
PRInt32
left
=
0
;
nsresult
nsres
;
...
...
@@ -865,11 +865,11 @@ static HRESULT WINAPI HTMLElement2_get_scrollLeft(IHTMLElement2 *iface, long *p)
return
E_NOTIMPL
;
}
nsres
=
nsIDOMHTMLElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNS
HTML
Element
,
(
void
**
)
&
nselem
);
nsres
=
nsIDOMHTMLElement_QueryInterface
(
This
->
nselem
,
&
IID_nsIDOMNSElement
,
(
void
**
)
&
nselem
);
if
(
NS_SUCCEEDED
(
nsres
))
{
nsres
=
nsIDOMNS
HTML
Element_GetScrollLeft
(
nselem
,
&
left
);
nsIDOMNS
HTML
Element_Release
(
nselem
);
nsres
=
nsIDOMNSElement_GetScrollLeft
(
nselem
,
&
left
);
nsIDOMNSElement_Release
(
nselem
);
if
(
NS_FAILED
(
nsres
))
left
=
0
;
}
...
...
dlls/mshtml/mshtml_private.h
View file @
8d28f09d
...
...
@@ -296,6 +296,13 @@ typedef struct {
NSContainer
*
This
;
}
nsEventListener
;
typedef
struct
_mutation_queue_t
{
DWORD
type
;
nsISupports
*
nsiface
;
struct
_mutation_queue_t
*
next
;
}
mutation_queue_t
;
struct
NSContainer
{
const
nsIWebBrowserChromeVtbl
*
lpWebBrowserChromeVtbl
;
const
nsIContextMenuListenerVtbl
*
lpContextMenuListenerVtbl
;
...
...
@@ -306,6 +313,10 @@ struct NSContainer {
const
nsIWeakReferenceVtbl
*
lpWeakReferenceVtbl
;
const
nsISupportsWeakReferenceVtbl
*
lpSupportsWeakReferenceVtbl
;
const
nsIDocumentObserverVtbl
*
lpDocumentObserverVtbl
;
const
nsIRunnableVtbl
*
lpRunnableVtbl
;
nsEventListener
blur_listener
;
nsEventListener
focus_listener
;
nsEventListener
keypress_listener
;
...
...
@@ -330,6 +341,9 @@ struct NSContainer {
HWND
hwnd
;
mutation_queue_t
*
mutation_queue
;
mutation_queue_t
*
mutation_queue_tail
;
nsChannelBSC
*
bscallback
;
/* hack */
HWND
reset_focus
;
/* hack */
...
...
@@ -434,6 +448,10 @@ typedef struct {
#define NSWEAKREF(x) ((nsIWeakReference*) &(x)->lpWeakReferenceVtbl)
#define NSSUPWEAKREF(x) ((nsISupportsWeakReference*) &(x)->lpSupportsWeakReferenceVtbl)
#define NSDOCOBS(x) ((nsIDocumentObserver*) &(x)->lpDocumentObserverVtbl)
#define NSRUNNABLE(x) ((nsIRunnable*) &(x)->lpRunnableVtbl)
#define NSCHANNEL(x) ((nsIChannel*) &(x)->lpHttpChannelVtbl)
#define NSHTTPCHANNEL(x) ((nsIHttpChannel*) &(x)->lpHttpChannelVtbl)
#define NSUPCHANNEL(x) ((nsIUploadChannel*) &(x)->lpUploadChannelVtbl)
...
...
@@ -487,6 +505,10 @@ void ConnectionPointContainer_Destroy(ConnectionPointContainer*);
NSContainer
*
NSContainer_Create
(
HTMLDocument
*
,
NSContainer
*
);
void
NSContainer_Release
(
NSContainer
*
);
void
init_mutation
(
NSContainer
*
);
void
set_mutation_observer
(
NSContainer
*
,
nsIDOMHTMLDocument
*
);
BOOL
handle_insert_comment
(
HTMLDocument
*
doc
,
const
PRUnichar
*
comment
);
void
HTMLDocument_LockContainer
(
HTMLDocument
*
,
BOOL
);
void
show_context_menu
(
HTMLDocument
*
,
DWORD
,
POINT
*
,
IDispatch
*
);
void
notif_focus
(
HTMLDocument
*
);
...
...
dlls/mshtml/mutation.c
0 → 100644
View file @
8d28f09d
This diff is collapsed.
Click to expand it.
dlls/mshtml/nsembed.c
View file @
8d28f09d
...
...
@@ -661,7 +661,7 @@ static void nsnode_to_nsstring_rec(nsIContentSerializer *serializer, nsIDOMNode
case
ELEMENT_NODE
:
{
nsIDOMElement
*
nselem
;
nsIDOMNode_QueryInterface
(
nsnode
,
&
IID_nsIDOMElement
,
(
void
**
)
&
nselem
);
nsIContentSerializer_AppendElementStart
(
serializer
,
nselem
,
has_children
,
str
);
nsIContentSerializer_AppendElementStart
(
serializer
,
nselem
,
nselem
,
str
);
nsIDOMElement_Release
(
nselem
);
break
;
}
...
...
@@ -733,7 +733,7 @@ void nsnode_to_nsstring(nsIDOMNode *nsdoc, nsAString *str)
return
;
}
nsres
=
nsIContentSerializer_Init
(
serializer
,
0
,
100
,
NULL
,
FALSE
);
nsres
=
nsIContentSerializer_Init
(
serializer
,
0
,
100
,
NULL
,
FALSE
,
FALSE
/* FIXME */
);
if
(
NS_FAILED
(
nsres
))
ERR
(
"Init failed: %08x
\n
"
,
nsres
);
...
...
@@ -816,7 +816,8 @@ void set_ns_editmode(NSContainer *This)
return
;
}
nsres
=
nsIEditingSession_MakeWindowEditable
(
editing_session
,
dom_window
,
NULL
,
FALSE
);
nsres
=
nsIEditingSession_MakeWindowEditable
(
editing_session
,
dom_window
,
NULL
,
FALSE
,
TRUE
,
TRUE
);
nsIEditingSession_Release
(
editing_session
);
nsIDOMWindow_Release
(
dom_window
);
if
(
NS_FAILED
(
nsres
))
{
...
...
@@ -865,6 +866,9 @@ void update_nsdocument(HTMLDocument *doc)
nsIDOMHTMLDocument_Release
(
doc
->
nsdoc
);
doc
->
nsdoc
=
nsdoc
;
if
(
nsdoc
)
set_mutation_observer
(
doc
->
nscontainer
,
nsdoc
);
}
void
close_gecko
(
void
)
...
...
@@ -1668,6 +1672,7 @@ NSContainer *NSContainer_Create(HTMLDocument *doc, NSContainer *parent)
ret
->
doc
=
doc
;
ret
->
ref
=
1
;
init_mutation
(
ret
);
nsres
=
nsIComponentManager_CreateInstanceByContractID
(
pCompMgr
,
NS_WEBBROWSER_CONTRACTID
,
NULL
,
&
IID_nsIWebBrowser
,
(
void
**
)
&
ret
->
webbrowser
);
...
...
dlls/mshtml/nsevents.c
View file @
8d28f09d
...
...
@@ -178,7 +178,7 @@ static nsresult NSAPI handle_load(nsIDOMEventListener *iface, nsIDOMEvent *event
#define IE_MAJOR_VERSION 7
#define IE_MINOR_VERSION 0
static
BOOL
handle_insert_comment
(
HTMLDocument
*
doc
,
const
PRUnichar
*
comment
)
BOOL
handle_insert_comment
(
HTMLDocument
*
doc
,
const
PRUnichar
*
comment
)
{
DWORD
len
;
int
majorv
=
0
,
minorv
=
0
;
...
...
@@ -484,8 +484,6 @@ void init_nsevents(NSContainer *This)
static
const
PRUnichar
wsz_focus
[]
=
{
'f'
,
'o'
,
'c'
,
'u'
,
's'
,
0
};
static
const
PRUnichar
wsz_keypress
[]
=
{
'k'
,
'e'
,
'y'
,
'p'
,
'r'
,
'e'
,
's'
,
's'
,
0
};
static
const
PRUnichar
wsz_load
[]
=
{
'l'
,
'o'
,
'a'
,
'd'
,
0
};
static
const
PRUnichar
DOMNodeInsertedW
[]
=
{
'D'
,
'O'
,
'M'
,
'N'
,
'o'
,
'd'
,
'e'
,
'I'
,
'n'
,
's'
,
'e'
,
'r'
,
't'
,
'e'
,
'd'
,
0
};
init_listener
(
&
This
->
blur_listener
,
This
,
&
blur_vtbl
);
init_listener
(
&
This
->
focus_listener
,
This
,
&
focus_vtbl
);
...
...
@@ -511,7 +509,6 @@ void init_nsevents(NSContainer *This)
init_event
(
target
,
wsz_focus
,
NSEVENTLIST
(
&
This
->
focus_listener
),
TRUE
);
init_event
(
target
,
wsz_keypress
,
NSEVENTLIST
(
&
This
->
keypress_listener
),
FALSE
);
init_event
(
target
,
wsz_load
,
NSEVENTLIST
(
&
This
->
load_listener
),
TRUE
);
init_event
(
target
,
DOMNodeInsertedW
,
NSEVENTLIST
(
&
This
->
node_insert_listener
),
TRUE
);
nsIDOMEventTarget_Release
(
target
);
}
dlls/mshtml/nsiface.idl
View file @
8d28f09d
This diff is collapsed.
Click to expand it.
dlls/mshtml/nsio.c
View file @
8d28f09d
...
...
@@ -2276,11 +2276,76 @@ static nsresult NSAPI nsNetUtil_ParseContentType(nsINetUtil *iface, const nsACSt
return
nsINetUtil_ParseContentType
(
net_util
,
aTypeHeader
,
aCharset
,
aHadCharset
,
aContentType
);
}
static
nsresult
NSAPI
nsNetUtil_ProtocolHasFlags
(
nsINetUtil
*
iface
,
nsIURI
*
aURI
,
PRUint32
aFlags
,
PRBool
*
_retval
)
{
TRACE
(
"()
\n
"
);
return
nsINetUtil_ProtocolHasFlags
(
net_util
,
aURI
,
aFlags
,
_retval
);
}
static
nsresult
NSAPI
nsNetUtil_URIChainHasFlags
(
nsINetUtil
*
iface
,
nsIURI
*
aURI
,
PRUint32
aFlags
,
PRBool
*
_retval
)
{
TRACE
(
"(%p %08x %p)
\n
"
,
aURI
,
aFlags
,
_retval
);
if
(
aFlags
==
(
1
<<
11
))
{
*
_retval
=
FALSE
;
return
NS_OK
;
}
return
nsINetUtil_URIChainHasFlags
(
net_util
,
aURI
,
aFlags
,
_retval
);
}
static
nsresult
NSAPI
nsNetUtil_ToImmutableURI
(
nsINetUtil
*
iface
,
nsIURI
*
aURI
,
nsIURI
**
_retval
)
{
TRACE
(
"(%p %p)
\n
"
,
aURI
,
_retval
);
return
nsINetUtil_ToImmutableURI
(
net_util
,
aURI
,
_retval
);
}
static
nsresult
NSAPI
nsNetUtil_EscapeString
(
nsINetUtil
*
iface
,
const
nsACString
*
aString
,
PRUint32
aEscapeType
,
nsACString
*
_retval
)
{
TRACE
(
"(%p %x %p)
\n
"
,
aString
,
aEscapeType
,
_retval
);
return
nsINetUtil_EscapeString
(
net_util
,
aString
,
aEscapeType
,
_retval
);
}
static
nsresult
NSAPI
nsNetUtil_EscapeURL
(
nsINetUtil
*
iface
,
const
nsACString
*
aStr
,
PRUint32
aFlags
,
nsACString
*
_retval
)
{
TRACE
(
"(%p %08x %p)
\n
"
,
aStr
,
aFlags
,
_retval
);
return
nsINetUtil_EscapeURL
(
net_util
,
aStr
,
aFlags
,
_retval
);
}
static
nsresult
NSAPI
nsNetUtil_UnescapeString
(
nsINetUtil
*
iface
,
const
nsACString
*
aStr
,
PRUint32
aFlags
,
nsACString
*
_retval
)
{
TRACE
(
"(%p %08x %p)
\n
"
,
aStr
,
aFlags
,
_retval
);
return
nsINetUtil_UnescapeString
(
net_util
,
aStr
,
aFlags
,
_retval
);
}
static
nsresult
NSAPI
nsNetUtil_ExtractCharsetFromContentType
(
nsINetUtil
*
iface
,
const
nsACString
*
aTypeHeader
,
nsACString
*
aCharset
,
PRInt32
*
aCharsetStart
,
PRInt32
*
aCharsetEnd
,
PRBool
*
_retval
)
{
TRACE
(
"(%p %p %p %p %p)
\n
"
,
aTypeHeader
,
aCharset
,
aCharsetStart
,
aCharsetEnd
,
_retval
);
return
nsINetUtil_ExtractCharsetFromContentType
(
net_util
,
aTypeHeader
,
aCharset
,
aCharsetStart
,
aCharsetEnd
,
_retval
);
}
static
const
nsINetUtilVtbl
nsNetUtilVtbl
=
{
nsNetUtil_QueryInterface
,
nsNetUtil_AddRef
,
nsNetUtil_Release
,
nsNetUtil_ParseContentType
nsNetUtil_ParseContentType
,
nsNetUtil_ProtocolHasFlags
,
nsNetUtil_URIChainHasFlags
,
nsNetUtil_ToImmutableURI
,
nsNetUtil_EscapeString
,
nsNetUtil_EscapeURL
,
nsNetUtil_UnescapeString
,
nsNetUtil_ExtractCharsetFromContentType
};
static
nsINetUtil
nsNetUtil
=
{
&
nsNetUtilVtbl
};
...
...
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