mshtml: Remove not used argument in nsAString_GetData.

This commit is contained in:
Jacek Caban 2007-12-17 01:38:30 +01:00 committed by Alexandre Julliard
parent 72d0971034
commit 559649c443
16 changed files with 34 additions and 34 deletions

View File

@ -253,7 +253,7 @@ static void remove_child_attr(nsIDOMElement *elem, LPCWSTR tag, nsAString *attr_
nsAString_Init(&tag_str, NULL); nsAString_Init(&tag_str, NULL);
nsIDOMElement_GetTagName(child_elem, &tag_str); nsIDOMElement_GetTagName(child_elem, &tag_str);
nsAString_GetData(&tag_str, &ctag, NULL); nsAString_GetData(&tag_str, &ctag);
if(!strcmpiW(ctag, tag)) if(!strcmpiW(ctag, tag))
/* FIXME: remove node if there are no more attributes */ /* FIXME: remove node if there are no more attributes */
@ -300,7 +300,7 @@ static void get_font_size(HTMLDocument *This, WCHAR *ret)
nsAString_Init(&tag_str, NULL); nsAString_Init(&tag_str, NULL);
nsIDOMElement_GetTagName(elem, &tag_str); nsIDOMElement_GetTagName(elem, &tag_str);
nsAString_GetData(&tag_str, &tag, NULL); nsAString_GetData(&tag_str, &tag);
if(!strcmpiW(tag, wszFont)) { if(!strcmpiW(tag, wszFont)) {
nsAString size_str, val_str; nsAString size_str, val_str;
@ -312,7 +312,7 @@ static void get_font_size(HTMLDocument *This, WCHAR *ret)
nsAString_Init(&val_str, NULL); nsAString_Init(&val_str, NULL);
nsIDOMElement_GetAttribute(elem, &size_str, &val_str); nsIDOMElement_GetAttribute(elem, &size_str, &val_str);
nsAString_GetData(&val_str, &val, NULL); nsAString_GetData(&val_str, &val);
if(*val) { if(*val) {
TRACE("found size %s\n", debugstr_w(val)); TRACE("found size %s\n", debugstr_w(val));

View File

@ -126,7 +126,7 @@ static HRESULT WINAPI HTMLBodyElement_get_background(IHTMLBodyElement *iface, BS
nsres = nsIDOMHTMLBodyElement_GetBackground(This->nsbody, &background_str); nsres = nsIDOMHTMLBodyElement_GetBackground(This->nsbody, &background_str);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
const PRUnichar *background; const PRUnichar *background;
nsAString_GetData(&background_str, &background, NULL); nsAString_GetData(&background_str, &background);
*p = *background ? SysAllocString(background) : NULL; *p = *background ? SysAllocString(background) : NULL;
}else { }else {
ERR("GetBackground failed: %08x\n", nsres); ERR("GetBackground failed: %08x\n", nsres);

View File

@ -243,7 +243,7 @@ static HRESULT WINAPI HTMLDocument5_get_compatMode(IHTMLDocument5 *iface, BSTR *
nsIDOMNSHTMLDocument_GetCompatMode(nshtmldoc, &mode_str); nsIDOMNSHTMLDocument_GetCompatMode(nshtmldoc, &mode_str);
nsIDOMNSHTMLDocument_Release(nshtmldoc); nsIDOMNSHTMLDocument_Release(nshtmldoc);
nsAString_GetData(&mode_str, &mode, NULL); nsAString_GetData(&mode_str, &mode);
*p = SysAllocString(mode); *p = SysAllocString(mode);
nsAString_Finish(&mode_str); nsAString_Finish(&mode_str);

View File

@ -191,7 +191,7 @@ static HRESULT WINAPI HTMLElement_getAttribute(IHTMLElement *iface, BSTR strAttr
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
static const WCHAR wszSRC[] = {'s','r','c',0}; static const WCHAR wszSRC[] = {'s','r','c',0};
nsAString_GetData(&value_str, &value, NULL); nsAString_GetData(&value_str, &value);
if(!strcmpiW(strAttributeName, wszSRC)) if(!strcmpiW(strAttributeName, wszSRC))
{ {
WCHAR buffer[256]; WCHAR buffer[256];
@ -253,7 +253,7 @@ static HRESULT WINAPI HTMLElement_get_className(IHTMLElement *iface, BSTR *p)
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
const PRUnichar *class; const PRUnichar *class;
nsAString_GetData(&class_str, &class, NULL); nsAString_GetData(&class_str, &class);
*p = SysAllocString(class); *p = SysAllocString(class);
}else { }else {
ERR("GetClassName failed: %08x\n", nsres); ERR("GetClassName failed: %08x\n", nsres);
@ -292,7 +292,7 @@ static HRESULT WINAPI HTMLElement_get_tagName(IHTMLElement *iface, BSTR *p)
nsAString_Init(&tag_str, NULL); nsAString_Init(&tag_str, NULL);
nsres = nsIDOMHTMLElement_GetTagName(This->nselem, &tag_str); nsres = nsIDOMHTMLElement_GetTagName(This->nselem, &tag_str);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
nsAString_GetData(&tag_str, &tag, NULL); nsAString_GetData(&tag_str, &tag);
*p = SysAllocString(tag); *p = SysAllocString(tag);
}else { }else {
ERR("GetTagName failed: %08x\n", nsres); ERR("GetTagName failed: %08x\n", nsres);
@ -1318,7 +1318,7 @@ HTMLElement *HTMLElement_Create(nsIDOMNode *nsnode)
nsAString_Init(&class_name_str, NULL); nsAString_Init(&class_name_str, NULL);
nsIDOMHTMLElement_GetTagName(nselem, &class_name_str); nsIDOMHTMLElement_GetTagName(nselem, &class_name_str);
nsAString_GetData(&class_name_str, &class_name, NULL); nsAString_GetData(&class_name_str, &class_name);
if(!strcmpW(class_name, wszA)) if(!strcmpW(class_name, wszA))
ret = HTMLAnchorElement_Create(nselem); ret = HTMLAnchorElement_Create(nselem);
@ -1495,7 +1495,7 @@ static BOOL is_elem_name(HTMLElement *elem, LPCWSTR name)
nsAString_Init(&nsstr, NULL); nsAString_Init(&nsstr, NULL);
nsIDOMHTMLElement_GetId(elem->nselem, &nsstr); nsIDOMHTMLElement_GetId(elem->nselem, &nsstr);
nsAString_GetData(&nsstr, &str, NULL); nsAString_GetData(&nsstr, &str);
if(!strcmpiW(str, name)) { if(!strcmpiW(str, name)) {
nsAString_Finish(&nsstr); nsAString_Finish(&nsstr);
return TRUE; return TRUE;
@ -1505,7 +1505,7 @@ static BOOL is_elem_name(HTMLElement *elem, LPCWSTR name)
nsres = nsIDOMHTMLElement_GetAttribute(elem->nselem, &nsname, &nsstr); nsres = nsIDOMHTMLElement_GetAttribute(elem->nselem, &nsname, &nsstr);
nsAString_Finish(&nsname); nsAString_Finish(&nsname);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
nsAString_GetData(&nsstr, &str, NULL); nsAString_GetData(&nsstr, &str);
ret = !strcmpiW(str, name); ret = !strcmpiW(str, name);
} }
@ -1615,7 +1615,7 @@ static HRESULT WINAPI HTMLElementCollection_tags(IHTMLElementCollection *iface,
continue; continue;
nsIDOMElement_GetTagName(This->elems[i]->nselem, &tag_str); nsIDOMElement_GetTagName(This->elems[i]->nselem, &tag_str);
nsAString_GetData(&tag_str, &tag, NULL); nsAString_GetData(&tag_str, &tag);
if(CompareStringW(LOCALE_SYSTEM_DEFAULT, NORM_IGNORECASE, tag, -1, if(CompareStringW(LOCALE_SYSTEM_DEFAULT, NORM_IGNORECASE, tag, -1,
V_BSTR(&tagName), -1) == CSTR_EQUAL) V_BSTR(&tagName), -1) == CSTR_EQUAL)

View File

@ -612,7 +612,7 @@ static HRESULT WINAPI HTMLElement2_get_dir(IHTMLElement2 *iface, BSTR *p)
nsres = nsIDOMHTMLElement_GetDir(This->nselem, &dir_str); nsres = nsIDOMHTMLElement_GetDir(This->nselem, &dir_str);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
const PRUnichar *dir; const PRUnichar *dir;
nsAString_GetData(&dir_str, &dir, NULL); nsAString_GetData(&dir_str, &dir);
if(*dir) if(*dir)
*p = SysAllocString(dir); *p = SysAllocString(dir);
}else { }else {

View File

@ -126,7 +126,7 @@ static HRESULT WINAPI HTMLInputElement_get_type(IHTMLInputElement *iface, BSTR *
nsres = nsIDOMHTMLInputElement_GetType(This->nsinput, &type_str); nsres = nsIDOMHTMLInputElement_GetType(This->nsinput, &type_str);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
nsAString_GetData(&type_str, &type, NULL); nsAString_GetData(&type_str, &type);
*p = SysAllocString(type); *p = SysAllocString(type);
}else { }else {
ERR("GetType failed: %08x\n", nsres); ERR("GetType failed: %08x\n", nsres);
@ -158,7 +158,7 @@ static HRESULT WINAPI HTMLInputElement_get_value(IHTMLInputElement *iface, BSTR
nsres = nsIDOMHTMLInputElement_GetValue(This->nsinput, &value_str); nsres = nsIDOMHTMLInputElement_GetValue(This->nsinput, &value_str);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
nsAString_GetData(&value_str, &value, NULL); nsAString_GetData(&value_str, &value);
*p = SysAllocString(value); *p = SysAllocString(value);
}else { }else {
ERR("GetValue failed: %08x\n", nsres); ERR("GetValue failed: %08x\n", nsres);
@ -190,7 +190,7 @@ static HRESULT WINAPI HTMLInputElement_get_name(IHTMLInputElement *iface, BSTR *
nsres = nsIDOMHTMLInputElement_GetName(This->nsinput, &name_str); nsres = nsIDOMHTMLInputElement_GetName(This->nsinput, &name_str);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
nsAString_GetData(&name_str, &name, NULL); nsAString_GetData(&name_str, &name);
*p = SysAllocString(name); *p = SysAllocString(name);
}else { }else {
ERR("GetName failed: %08x\n", nsres); ERR("GetName failed: %08x\n", nsres);

View File

@ -223,7 +223,7 @@ static HRESULT WINAPI HTMLDOMNode_get_nodeName(IHTMLDOMNode *iface, BSTR *p)
nsres = nsIDOMNode_GetNodeName(This->nsnode, &name_str); nsres = nsIDOMNode_GetNodeName(This->nsnode, &name_str);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
nsAString_GetData(&name_str, &name, NULL); nsAString_GetData(&name_str, &name);
*p = SysAllocString(name); *p = SysAllocString(name);
}else { }else {
ERR("GetNodeName failed: %08x\n", nsres); ERR("GetNodeName failed: %08x\n", nsres);

View File

@ -147,7 +147,7 @@ static HRESULT WINAPI HTMLOptionElement_get_value(IHTMLOptionElement *iface, BST
nsAString_Init(&value_str, NULL); nsAString_Init(&value_str, NULL);
nsres = nsIDOMHTMLOptionElement_GetValue(This->nsoption, &value_str); nsres = nsIDOMHTMLOptionElement_GetValue(This->nsoption, &value_str);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
nsAString_GetData(&value_str, &value, NULL); nsAString_GetData(&value_str, &value);
*p = SysAllocString(value); *p = SysAllocString(value);
}else { }else {
ERR("GetValue failed: %08x\n", nsres); ERR("GetValue failed: %08x\n", nsres);
@ -250,7 +250,7 @@ static HRESULT WINAPI HTMLOptionElement_get_text(IHTMLOptionElement *iface, BSTR
nsAString_Init(&text_str, NULL); nsAString_Init(&text_str, NULL);
nsres = nsIDOMHTMLOptionElement_GetText(This->nsoption, &text_str); nsres = nsIDOMHTMLOptionElement_GetText(This->nsoption, &text_str);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
nsAString_GetData(&text_str, &text, NULL); nsAString_GetData(&text_str, &text);
*p = SysAllocString(text); *p = SysAllocString(text);
}else { }else {
ERR("GetText failed: %08x\n", nsres); ERR("GetText failed: %08x\n", nsres);

View File

@ -154,7 +154,7 @@ static HRESULT WINAPI HTMLSelectElement_get_name(IHTMLSelectElement *iface, BSTR
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
static const WCHAR wszGarbage[] = {'g','a','r','b','a','g','e',0}; static const WCHAR wszGarbage[] = {'g','a','r','b','a','g','e',0};
nsAString_GetData(&name_str, &name, NULL); nsAString_GetData(&name_str, &name);
/* /*
* Native never returns empty string here. If an element has no name, * Native never returns empty string here. If an element has no name,
@ -249,7 +249,7 @@ static HRESULT WINAPI HTMLSelectElement_get_value(IHTMLSelectElement *iface, BST
nsres = nsIDOMHTMLSelectElement_GetValue(This->nsselect, &value_str); nsres = nsIDOMHTMLSelectElement_GetValue(This->nsselect, &value_str);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
nsAString_GetData(&value_str, &value, NULL); nsAString_GetData(&value_str, &value);
*p = SysAllocString(value); *p = SysAllocString(value);
}else { }else {
ERR("GetValue failed: %08x\n", nsres); ERR("GetValue failed: %08x\n", nsres);

View File

@ -175,7 +175,7 @@ static HRESULT get_style_attr(HTMLStyle *This, LPCWSTR name, BSTR *p)
get_style_attr_nsval(This, name, &str_value); get_style_attr_nsval(This, name, &str_value);
nsAString_GetData(&str_value, &value, NULL); nsAString_GetData(&str_value, &value);
*p = *value ? SysAllocString(value) : NULL; *p = *value ? SysAllocString(value) : NULL;
nsAString_Finish(&str_value); nsAString_Finish(&str_value);
@ -193,7 +193,7 @@ static HRESULT check_style_attr_value(HTMLStyle *This, LPCWSTR name, LPCWSTR exv
get_style_attr_nsval(This, name, &str_value); get_style_attr_nsval(This, name, &str_value);
nsAString_GetData(&str_value, &value, NULL); nsAString_GetData(&str_value, &value);
*p = strcmpW(value, exval) ? VARIANT_FALSE : VARIANT_TRUE; *p = strcmpW(value, exval) ? VARIANT_FALSE : VARIANT_TRUE;
nsAString_Finish(&str_value); nsAString_Finish(&str_value);

View File

@ -131,7 +131,7 @@ static HRESULT WINAPI HTMLTextAreaElement_get_value(IHTMLTextAreaElement *iface,
nsres = nsIDOMHTMLTextAreaElement_GetValue(This->nstextarea, &value_str); nsres = nsIDOMHTMLTextAreaElement_GetValue(This->nstextarea, &value_str);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
nsAString_GetData(&value_str, &value, NULL); nsAString_GetData(&value_str, &value);
*p = SysAllocString(value); *p = SysAllocString(value);
}else { }else {
ERR("GetValue failed: %08x\n", nsres); ERR("GetValue failed: %08x\n", nsres);
@ -163,7 +163,7 @@ static HRESULT WINAPI HTMLTextAreaElement_get_name(IHTMLTextAreaElement *iface,
nsres = nsIDOMHTMLTextAreaElement_GetName(This->nstextarea, &name_str); nsres = nsIDOMHTMLTextAreaElement_GetName(This->nstextarea, &name_str);
if(NS_SUCCEEDED(nsres)) { if(NS_SUCCEEDED(nsres)) {
nsAString_GetData(&name_str, &name, NULL); nsAString_GetData(&name_str, &name);
*p = SysAllocString(name); *p = SysAllocString(name);
}else { }else {
ERR("GetName failed: %08x\n", nsres); ERR("GetName failed: %08x\n", nsres);

View File

@ -412,7 +412,7 @@ PRUint32 nsACString_GetData(const nsACString*,const char**);
void nsACString_Finish(nsACString*); void nsACString_Finish(nsACString*);
void nsAString_Init(nsAString*,const PRUnichar*); void nsAString_Init(nsAString*,const PRUnichar*);
PRUint32 nsAString_GetData(const nsAString*,const PRUnichar**,PRBool*); PRUint32 nsAString_GetData(const nsAString*,const PRUnichar**);
void nsAString_Finish(nsAString*); void nsAString_Finish(nsAString*);
nsIInputStream *create_nsstream(const char*,PRInt32); nsIInputStream *create_nsstream(const char*,PRInt32);

View File

@ -489,9 +489,9 @@ void nsAString_Init(nsAString *str, const PRUnichar *data)
NS_StringSetData(str, data, PR_UINT32_MAX); NS_StringSetData(str, data, PR_UINT32_MAX);
} }
PRUint32 nsAString_GetData(const nsAString *str, const PRUnichar **data, PRBool *termited) PRUint32 nsAString_GetData(const nsAString *str, const PRUnichar **data)
{ {
return NS_StringGetData(str, data, termited); return NS_StringGetData(str, data, NULL);
} }
void nsAString_Finish(nsAString *str) void nsAString_Finish(nsAString *str)

View File

@ -334,7 +334,7 @@ static nsresult NSAPI nsTooltipTextProvider_GetNodeText(nsITooltipTextProvider *
nsIDOMHTMLElement_GetTitle(nselem, &title_str); nsIDOMHTMLElement_GetTitle(nselem, &title_str);
nsIDOMHTMLElement_Release(nselem); nsIDOMHTMLElement_Release(nselem);
nsAString_GetData(&title_str, &title, NULL); nsAString_GetData(&title_str, &title);
if(title && *title) { if(title && *title) {
if(node != aNode) if(node != aNode)
nsIDOMNode_Release(node); nsIDOMNode_Release(node);

View File

@ -362,7 +362,7 @@ static HRESULT get_doc_string(HTMLDocument *This, char **str, DWORD *len)
nsnode_to_nsstring(nsnode, &nsstr); nsnode_to_nsstring(nsnode, &nsstr);
nsIDOMNode_Release(nsnode); nsIDOMNode_Release(nsnode);
nsAString_GetData(&nsstr, &strw, NULL); nsAString_GetData(&nsstr, &strw);
TRACE("%s\n", debugstr_w(strw)); TRACE("%s\n", debugstr_w(strw));
*len = WideCharToMultiByte(CP_ACP, 0, strw, -1, NULL, 0, NULL, NULL); *len = WideCharToMultiByte(CP_ACP, 0, strw, -1, NULL, 0, NULL, NULL);

View File

@ -147,7 +147,7 @@ static BOOL is_br_node(nsIDOMNode *node)
nsAString_Init(&tag_str, NULL); nsAString_Init(&tag_str, NULL);
nsIDOMElement_GetTagName(elem, &tag_str); nsIDOMElement_GetTagName(elem, &tag_str);
nsIDOMElement_Release(elem); nsIDOMElement_Release(elem);
nsAString_GetData(&tag_str, &tag, 0); nsAString_GetData(&tag_str, &tag);
if(!strcmpiW(tag, brW)) if(!strcmpiW(tag, brW))
ret = TRUE; ret = TRUE;
@ -233,7 +233,7 @@ static void wstrbuf_append_node(wstrbuf_t *buf, nsIDOMNode *node)
nsAString_Init(&data_str, NULL); nsAString_Init(&data_str, NULL);
nsIDOMText_GetData(nstext, &data_str); nsIDOMText_GetData(nstext, &data_str);
nsAString_GetData(&data_str, &data, NULL); nsAString_GetData(&data_str, &data);
wstrbuf_append_nodetxt(buf, data, strlenW(data)); wstrbuf_append_nodetxt(buf, data, strlenW(data));
nsAString_Finish(&data_str); nsAString_Finish(&data_str);
@ -264,7 +264,7 @@ static BOOL fill_nodestr(dompos_t *pos)
nsAString_Init(&pos->str, NULL); nsAString_Init(&pos->str, NULL);
nsIDOMText_GetData(text, &pos->str); nsIDOMText_GetData(text, &pos->str);
nsIDOMText_Release(text); nsIDOMText_Release(text);
nsAString_GetData(&pos->str, &pos->p, NULL); nsAString_GetData(&pos->str, &pos->p);
if(pos->off == -1) if(pos->off == -1)
pos->off = *pos->p ? strlenW(pos->p)-1 : 0; pos->off = *pos->p ? strlenW(pos->p)-1 : 0;
@ -1042,7 +1042,7 @@ static HRESULT WINAPI HTMLTxtRange_get_htmlText(IHTMLTxtRange *iface, BSTR *p)
nsnode_to_nsstring((nsIDOMNode*)fragment, &nsstr); nsnode_to_nsstring((nsIDOMNode*)fragment, &nsstr);
nsIDOMDocumentFragment_Release(fragment); nsIDOMDocumentFragment_Release(fragment);
nsAString_GetData(&nsstr, &nstext, NULL); nsAString_GetData(&nsstr, &nstext);
*p = SysAllocString(nstext); *p = SysAllocString(nstext);
nsAString_Finish(&nsstr); nsAString_Finish(&nsstr);