File: document.bnd

package info (click to toggle)
netsurf 3.11-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 87,296 kB
  • sloc: ansic: 403,115; xml: 81,988; cpp: 6,246; perl: 4,605; makefile: 2,907; yacc: 2,246; python: 2,057; sh: 1,500; jsp: 1,156; lex: 623; javascript: 551; ruby: 329; asm: 326; lisp: 151; php: 6
file content (16 lines) | stat: -rw-r--r-- 470 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
/* test binding for document - must be included */

webidlfile "eventtarget.idl";
webidlfile "node.idl";
webidlfile "document.idl";

operation getElementById %{
	dom_string *elementId_dom;
	dom_element *element;

	dom_string_create((unsigned char*)elementId, elementId_len, &elementId_dom);

	dom_document_get_element_by_id(private->node, elementId_dom, &element);

	jsretval = OBJECT_TO_JSVAL(jsapi_new_element(cx, JS_GetGlobalObject(cx), private->htmlc, element));
%}