mshtml: Added IHTMLTableCell::cellIndex method implementation.
This commit is contained in:
parent
b42fe709d6
commit
05f65a9341
|
@ -268,8 +268,16 @@ static HRESULT WINAPI HTMLTableCell_get_height(IHTMLTableCell *iface, VARIANT *p
|
|||
static HRESULT WINAPI HTMLTableCell_get_cellIndex(IHTMLTableCell *iface, LONG *p)
|
||||
{
|
||||
HTMLTableCell *This = impl_from_IHTMLTableCell(iface);
|
||||
FIXME("(%p)->(%p)\n", This, p);
|
||||
return E_NOTIMPL;
|
||||
nsresult nsres;
|
||||
|
||||
TRACE("(%p)->(%p)\n", This, p);
|
||||
nsres = nsIDOMHTMLTableCellElement_GetCellIndex(This->nscell, p);
|
||||
if (NS_FAILED(nsres)) {
|
||||
ERR("Get CellIndex failed: %08x\n", nsres);
|
||||
return E_FAIL;
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
static const IHTMLTableCellVtbl HTMLTableCellVtbl = {
|
||||
|
|
|
@ -5852,6 +5852,25 @@ static void test_tr_elem(IHTMLElement *elem)
|
|||
IHTMLTableRow_Release(row);
|
||||
}
|
||||
|
||||
static void test_td_elem(IHTMLElement *elem)
|
||||
{
|
||||
IHTMLTableCell *cell;
|
||||
HRESULT hres;
|
||||
LONG lval;
|
||||
|
||||
hres = IHTMLElement_QueryInterface(elem, &IID_IHTMLTableCell, (void**)&cell);
|
||||
ok(hres == S_OK, "Could not get IHTMLTableRow iface: %08x\n", hres);
|
||||
if(FAILED(hres))
|
||||
return;
|
||||
|
||||
lval = 0xdeadbeef;
|
||||
hres = IHTMLTableCell_get_cellIndex(cell, &lval);
|
||||
ok(hres == S_OK, "get cellIndex failed: %08x\n", hres);
|
||||
ok(lval == 1, "Expected 1, got %d\n", lval);
|
||||
|
||||
IHTMLTableCell_Release(cell);
|
||||
}
|
||||
|
||||
static void test_label_elem(IHTMLElement *elem)
|
||||
{
|
||||
IHTMLLabelElement *label;
|
||||
|
@ -6813,6 +6832,13 @@ static void test_elems(IHTMLDocument2 *doc)
|
|||
IHTMLElement_Release(elem);
|
||||
}
|
||||
|
||||
elem = get_doc_elem_by_id(doc, "td2");
|
||||
ok(elem != NULL, "elem == NULL\n");
|
||||
if(elem) {
|
||||
test_td_elem(elem);
|
||||
IHTMLElement_Release(elem);
|
||||
}
|
||||
|
||||
elem = get_doc_elem_by_id(doc, "row2");
|
||||
ok(elem != NULL, "elem == NULL\n");
|
||||
if(elem) {
|
||||
|
|
Loading…
Reference in New Issue