Commit 945dccb7 authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

msxml3: Implement get_line() and get_linepos().

parent cfce8ab4
......@@ -135,13 +135,10 @@ static HRESULT WINAPI parseError_GetTypeInfo(
ITypeInfo** ppTInfo )
{
parse_error_t *This = impl_from_IXMLDOMParseError( iface );
HRESULT hr;
TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
hr = get_typeinfo(IXMLDOMParseError_tid, ppTInfo);
return hr;
return get_typeinfo(IXMLDOMParseError_tid, ppTInfo);
}
static HRESULT WINAPI parseError_GetIDsOfNames(
......@@ -255,8 +252,13 @@ static HRESULT WINAPI parseError_get_line(
LONG *line )
{
parse_error_t *This = impl_from_IXMLDOMParseError( iface );
FIXME("(%p)->(%p)\n", This, line);
return E_NOTIMPL;
TRACE("(%p)->(%p): stub\n", This, line);
if (!line) return E_INVALIDARG;
*line = This->line;
return S_OK;
}
static HRESULT WINAPI parseError_get_linepos(
......@@ -264,8 +266,13 @@ static HRESULT WINAPI parseError_get_linepos(
LONG *linepos )
{
parse_error_t *This = impl_from_IXMLDOMParseError( iface );
FIXME("(%p)->(%p)\n", This, linepos);
return E_NOTIMPL;
TRACE("(%p)->(%p)\n", This, linepos);
if (!linepos) return E_INVALIDARG;
*linepos = This->linepos;
return S_OK;
}
static HRESULT WINAPI parseError_get_filepos(
......
......@@ -10752,6 +10752,31 @@ static void test_dispex(void)
free_bstrs();
}
static void test_parseerror(void)
{
IXMLDOMParseError *error;
IXMLDOMDocument *doc;
HRESULT hr;
doc = create_document(&IID_IXMLDOMDocument);
hr = IXMLDOMDocument_get_parseError(doc, &error);
EXPECT_HR(hr, S_OK);
hr = IXMLDOMParseError_get_line(error, NULL);
EXPECT_HR(hr, E_INVALIDARG);
hr = IXMLDOMParseError_get_srcText(error, NULL);
todo_wine EXPECT_HR(hr, E_INVALIDARG);
hr = IXMLDOMParseError_get_linepos(error, NULL);
EXPECT_HR(hr, E_INVALIDARG);
IXMLDOMParseError_Release(error);
IXMLDOMDocument_Release(doc);
}
START_TEST(domdoc)
{
IXMLDOMDocument *doc;
......@@ -10824,6 +10849,7 @@ START_TEST(domdoc)
test_selection();
test_load();
test_dispex();
test_parseerror();
test_xsltemplate();
......
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