Commit 5c8c46db authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

mshtml: Reorder nsIURL functions to match vtbl order.

parent 98b8ebaf
......@@ -2174,57 +2174,6 @@ static nsresult NSAPI nsURI_SetPath(nsIURL *iface, const nsACString *aPath)
return NS_OK;
}
static nsresult NSAPI nsURL_GetRef(nsIURL *iface, nsACString *aRef)
{
nsWineURI *This = impl_from_nsIURL(iface);
char *refa = NULL;
BSTR ref;
HRESULT hres;
TRACE("(%p)->(%p)\n", This, aRef);
if(!ensure_uri(This))
return NS_ERROR_UNEXPECTED;
hres = IUri_GetFragment(This->uri, &ref);
if(FAILED(hres))
return NS_ERROR_UNEXPECTED;
refa = heap_strdupWtoA(ref);
SysFreeString(ref);
if(ref && !refa)
return NS_ERROR_OUT_OF_MEMORY;
nsACString_SetData(aRef, refa && *refa == '#' ? refa+1 : refa);
heap_free(refa);
return NS_OK;
}
static nsresult NSAPI nsURL_SetRef(nsIURL *iface, const nsACString *aRef)
{
nsWineURI *This = impl_from_nsIURL(iface);
const char *refa;
WCHAR *ref;
HRESULT hres;
TRACE("(%p)->(%s)\n", This, debugstr_nsacstr(aRef));
if(!ensure_uri_builder(This))
return NS_ERROR_UNEXPECTED;
nsACString_GetData(aRef, &refa);
ref = heap_strdupAtoW(refa);
if(!ref)
return NS_ERROR_OUT_OF_MEMORY;
hres = IUriBuilder_SetFragment(This->uri_builder, ref);
heap_free(ref);
if(FAILED(hres))
return NS_ERROR_UNEXPECTED;
return NS_OK;
}
static nsresult NSAPI nsURI_Equals(nsIURL *iface, nsIURI *other, PRBool *_retval)
{
nsWineURI *This = impl_from_nsIURL(iface);
......@@ -2386,6 +2335,57 @@ static nsresult NSAPI nsURI_GetOriginCharset(nsIURL *iface, nsACString *aOriginC
return NS_ERROR_NOT_IMPLEMENTED;
}
static nsresult NSAPI nsURL_GetRef(nsIURL *iface, nsACString *aRef)
{
nsWineURI *This = impl_from_nsIURL(iface);
char *refa = NULL;
BSTR ref;
HRESULT hres;
TRACE("(%p)->(%p)\n", This, aRef);
if(!ensure_uri(This))
return NS_ERROR_UNEXPECTED;
hres = IUri_GetFragment(This->uri, &ref);
if(FAILED(hres))
return NS_ERROR_UNEXPECTED;
refa = heap_strdupWtoA(ref);
SysFreeString(ref);
if(ref && !refa)
return NS_ERROR_OUT_OF_MEMORY;
nsACString_SetData(aRef, refa && *refa == '#' ? refa+1 : refa);
heap_free(refa);
return NS_OK;
}
static nsresult NSAPI nsURL_SetRef(nsIURL *iface, const nsACString *aRef)
{
nsWineURI *This = impl_from_nsIURL(iface);
const char *refa;
WCHAR *ref;
HRESULT hres;
TRACE("(%p)->(%s)\n", This, debugstr_nsacstr(aRef));
if(!ensure_uri_builder(This))
return NS_ERROR_UNEXPECTED;
nsACString_GetData(aRef, &refa);
ref = heap_strdupAtoW(refa);
if(!ref)
return NS_ERROR_OUT_OF_MEMORY;
hres = IUriBuilder_SetFragment(This->uri_builder, ref);
heap_free(ref);
if(FAILED(hres))
return NS_ERROR_UNEXPECTED;
return NS_OK;
}
static nsresult NSAPI nsURI_EqualsExceptRef(nsIURL *iface, nsIURI *other, PRBool *_retval)
{
nsWineURI *This = impl_from_nsIURL(iface);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment