static HRESULT WINAPI HTMLBodyElement_put_aLink(IHTMLBodyElement *iface, VARIANT v) { HTMLBodyElement *This = impl_from_IHTMLBodyElement(iface); nsAString alink_str; nsresult nsres; TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); if(!variant_to_nscolor(&v, &alink_str)) return S_OK; nsres = nsIDOMHTMLBodyElement_SetALink(This->nsbody, &alink_str); nsAString_Finish(&alink_str); if(NS_FAILED(nsres)) ERR("SetALink failed: %08x\n", nsres); return S_OK; }
static HRESULT WINAPI HTMLBodyElement_put_bgColor(IHTMLBodyElement *iface, VARIANT v) { HTMLBodyElement *This = impl_from_IHTMLBodyElement(iface); nsAString strColor; nsresult nsres; TRACE("(%p)->()\n", This); if(!variant_to_nscolor(&v, &strColor)) return S_OK; nsres = nsIDOMHTMLBodyElement_SetBgColor(This->nsbody, &strColor); nsAString_Finish(&strColor); if(NS_FAILED(nsres)) ERR("SetBgColor failed: %08x\n", nsres); return S_OK; }
static HRESULT WINAPI HTMLBodyElement_put_text(IHTMLBodyElement *iface, VARIANT v) { HTMLBodyElement *This = impl_from_IHTMLBodyElement(iface); nsAString text; nsresult nsres; TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); if(!variant_to_nscolor(&v, &text)) return S_OK; nsres = nsIDOMHTMLBodyElement_SetText(This->nsbody, &text); nsAString_Finish(&text); if(NS_FAILED(nsres)) { ERR("SetText failed: %08x\n", nsres); return E_FAIL; } return S_OK; }
static HRESULT WINAPI HTMLTable_put_bgColor(IHTMLTable *iface, VARIANT v) { HTMLTable *This = impl_from_IHTMLTable(iface); nsAString val; nsresult nsres; TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); if(!variant_to_nscolor(&v, &val)) return S_OK; nsres = nsIDOMHTMLTableElement_SetBgColor(This->nstable, &val); nsAString_Finish(&val); if (NS_FAILED(nsres)){ ERR("Set BgColor(%s) failed!\n", debugstr_variant(&v)); return E_FAIL; } return S_OK; }
static HRESULT WINAPI HTMLTableCell_put_bgColor(IHTMLTableCell *iface, VARIANT v) { HTMLTableCell *This = impl_from_IHTMLTableCell(iface); nsAString strColor; nsresult nsres; TRACE("(%p)->(%s)\n", This, debugstr_variant(&v)); if(!variant_to_nscolor(&v, &strColor)) return S_OK; nsres = nsIDOMHTMLTableCellElement_SetBgColor(This->nscell, &strColor); nsAString_Finish(&strColor); if(NS_FAILED(nsres)) { ERR("SetBgColor(%s) failed: %08x\n", debugstr_variant(&v), nsres); return E_FAIL; } return S_OK; }