1 /* 2 * Copyright (C) 2005 Apple Computer, Inc. All rights reserved. 3 * Copyright (C) 2008 Luke Kenneth Casson Leighton <lkcl (at) lkcl.net> 4 * Copyright (C) 2008 Martin Soto <soto (at) freedesktop.org> 5 * Copyright (C) 2010 Igalia S.L. 6 * 7 * This file is derived by hand from an automatically generated file. 8 * Keeping it up-to-date could potentially be done by adding 9 * a make_names.pl generator, or by writing a separate 10 * generater which takes JSHTMLElementWrapperFactory.h as input. 11 * 12 * Redistribution and use in source and binary forms, with or without 13 * modification, are permitted provided that the following conditions 14 * are met: 15 * 1. Redistributions of source code must retain the above copyright 16 * notice, this list of conditions and the following disclaimer. 17 * 2. Redistributions in binary form must reproduce the above copyright 18 * notice, this list of conditions and the following disclaimer in the 19 * documentation and/or other materials provided with the distribution. 20 * 21 * THIS SOFTWARE IS PROVIDED BY APPLE COMPUTER, INC. ``AS IS'' AND ANY 22 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 24 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE COMPUTER, INC. OR 25 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 26 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 27 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 28 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY 29 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 30 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 31 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 32 */ 33 34 #include "config.h" 35 #include "WebKitHTMLElementWrapperFactory.h" 36 37 #include "HTMLAnchorElement.h" 38 #include "HTMLAppletElement.h" 39 #include "HTMLAreaElement.h" 40 #include "HTMLAudioElement.h" 41 #include "HTMLBRElement.h" 42 #include "HTMLBaseElement.h" 43 #include "HTMLBaseFontElement.h" 44 #include "HTMLBlockquoteElement.h" 45 #include "HTMLBodyElement.h" 46 #include "HTMLButtonElement.h" 47 #include "HTMLCanvasElement.h" 48 #include "HTMLDListElement.h" 49 #include "HTMLDirectoryElement.h" 50 #include "HTMLDivElement.h" 51 #include "HTMLEmbedElement.h" 52 #include "HTMLFieldSetElement.h" 53 #include "HTMLFontElement.h" 54 #include "HTMLFormElement.h" 55 #include "HTMLFrameElement.h" 56 #include "HTMLFrameSetElement.h" 57 #include "HTMLHRElement.h" 58 #include "HTMLHeadElement.h" 59 #include "HTMLHeadingElement.h" 60 #include "HTMLHtmlElement.h" 61 #include "HTMLIFrameElement.h" 62 #include "HTMLImageElement.h" 63 #include "HTMLInputElement.h" 64 #include "HTMLIsIndexElement.h" 65 #include "HTMLKeygenElement.h" 66 #include "HTMLLIElement.h" 67 #include "HTMLLabelElement.h" 68 #include "HTMLLegendElement.h" 69 #include "HTMLLinkElement.h" 70 #include "HTMLMapElement.h" 71 #include "HTMLMarqueeElement.h" 72 #include "HTMLMenuElement.h" 73 #include "HTMLMetaElement.h" 74 #include "HTMLModElement.h" 75 #include "HTMLNames.h" 76 #include "HTMLOListElement.h" 77 #include "HTMLObjectElement.h" 78 #include "HTMLOptGroupElement.h" 79 #include "HTMLOptionElement.h" 80 #include "HTMLParagraphElement.h" 81 #include "HTMLParamElement.h" 82 #include "HTMLPreElement.h" 83 #include "HTMLQuoteElement.h" 84 #include "HTMLScriptElement.h" 85 #include "HTMLSelectElement.h" 86 #include "HTMLStyleElement.h" 87 #include "HTMLTableCaptionElement.h" 88 #include "HTMLTableCellElement.h" 89 #include "HTMLTableColElement.h" 90 #include "HTMLTableElement.h" 91 #include "HTMLTableRowElement.h" 92 #include "HTMLTableSectionElement.h" 93 #include "HTMLTextAreaElement.h" 94 #include "HTMLTitleElement.h" 95 #include "HTMLUListElement.h" 96 #include "HTMLVideoElement.h" 97 98 #include "webkit/WebKitDOMHTMLAnchorElementPrivate.h" 99 #include "webkit/WebKitDOMHTMLAppletElementPrivate.h" 100 #include "webkit/WebKitDOMHTMLAreaElementPrivate.h" 101 #include "webkit/WebKitDOMHTMLBRElementPrivate.h" 102 #include "webkit/WebKitDOMHTMLBaseElementPrivate.h" 103 #include "webkit/WebKitDOMHTMLBaseFontElementPrivate.h" 104 #include "webkit/WebKitDOMHTMLBlockquoteElementPrivate.h" 105 #include "webkit/WebKitDOMHTMLBodyElementPrivate.h" 106 #include "webkit/WebKitDOMHTMLButtonElementPrivate.h" 107 #include "webkit/WebKitDOMHTMLCanvasElementPrivate.h" 108 #include "webkit/WebKitDOMHTMLDListElementPrivate.h" 109 #include "webkit/WebKitDOMHTMLDirectoryElementPrivate.h" 110 #include "webkit/WebKitDOMHTMLDivElementPrivate.h" 111 #include "webkit/WebKitDOMHTMLElementPrivate.h" 112 #include "webkit/WebKitDOMHTMLEmbedElementPrivate.h" 113 #include "webkit/WebKitDOMHTMLFieldSetElementPrivate.h" 114 #include "webkit/WebKitDOMHTMLFontElementPrivate.h" 115 #include "webkit/WebKitDOMHTMLFormElementPrivate.h" 116 #include "webkit/WebKitDOMHTMLFrameElementPrivate.h" 117 #include "webkit/WebKitDOMHTMLFrameSetElementPrivate.h" 118 #include "webkit/WebKitDOMHTMLHRElementPrivate.h" 119 #include "webkit/WebKitDOMHTMLHeadElementPrivate.h" 120 #include "webkit/WebKitDOMHTMLHeadingElementPrivate.h" 121 #include "webkit/WebKitDOMHTMLHtmlElementPrivate.h" 122 #include "webkit/WebKitDOMHTMLIFrameElementPrivate.h" 123 #include "webkit/WebKitDOMHTMLImageElementPrivate.h" 124 #include "webkit/WebKitDOMHTMLInputElementPrivate.h" 125 #include "webkit/WebKitDOMHTMLIsIndexElementPrivate.h" 126 #include "webkit/WebKitDOMHTMLKeygenElementPrivate.h" 127 #include "webkit/WebKitDOMHTMLLIElementPrivate.h" 128 #include "webkit/WebKitDOMHTMLLabelElementPrivate.h" 129 #include "webkit/WebKitDOMHTMLLegendElementPrivate.h" 130 #include "webkit/WebKitDOMHTMLLinkElementPrivate.h" 131 #include "webkit/WebKitDOMHTMLMapElementPrivate.h" 132 #include "webkit/WebKitDOMHTMLMarqueeElementPrivate.h" 133 #include "webkit/WebKitDOMHTMLMenuElementPrivate.h" 134 #include "webkit/WebKitDOMHTMLMetaElementPrivate.h" 135 #include "webkit/WebKitDOMHTMLModElementPrivate.h" 136 #include "webkit/WebKitDOMHTMLOListElementPrivate.h" 137 #include "webkit/WebKitDOMHTMLObjectElementPrivate.h" 138 #include "webkit/WebKitDOMHTMLOptGroupElementPrivate.h" 139 #include "webkit/WebKitDOMHTMLOptionElementPrivate.h" 140 #include "webkit/WebKitDOMHTMLParagraphElementPrivate.h" 141 #include "webkit/WebKitDOMHTMLParamElementPrivate.h" 142 #include "webkit/WebKitDOMHTMLPreElementPrivate.h" 143 #include "webkit/WebKitDOMHTMLQuoteElementPrivate.h" 144 #include "webkit/WebKitDOMHTMLScriptElementPrivate.h" 145 #include "webkit/WebKitDOMHTMLSelectElementPrivate.h" 146 #include "webkit/WebKitDOMHTMLStyleElementPrivate.h" 147 #include "webkit/WebKitDOMHTMLTableCaptionElementPrivate.h" 148 #include "webkit/WebKitDOMHTMLTableCellElementPrivate.h" 149 #include "webkit/WebKitDOMHTMLTableColElementPrivate.h" 150 #include "webkit/WebKitDOMHTMLTableElementPrivate.h" 151 #include "webkit/WebKitDOMHTMLTableRowElementPrivate.h" 152 #include "webkit/WebKitDOMHTMLTableSectionElementPrivate.h" 153 #include "webkit/WebKitDOMHTMLTextAreaElementPrivate.h" 154 #include "webkit/WebKitDOMHTMLTitleElementPrivate.h" 155 #include "webkit/WebKitDOMHTMLUListElementPrivate.h" 156 #include "webkit/webkitdom.h" 157 158 #if ENABLE(VIDEO) 159 #include "webkit/WebKitDOMHTMLAudioElementPrivate.h" 160 #include "webkit/WebKitDOMHTMLVideoElementPrivate.h" 161 #endif 162 163 #include <wtf/text/CString.h> 164 165 namespace WebKit { 166 167 using namespace WebCore; 168 using namespace WebCore::HTMLNames; 169 170 typedef gpointer (*CreateHTMLElementWrapperFunction)(PassRefPtr<HTMLElement>); 171 172 static gpointer createAnchorWrapper(PassRefPtr<HTMLElement> element) 173 { 174 return wrapHTMLAnchorElement(static_cast<HTMLAnchorElement*>(element.get())); 175 } 176 177 static gpointer createAppletWrapper(PassRefPtr<HTMLElement> element) 178 { 179 return wrapHTMLAppletElement(static_cast<HTMLAppletElement*>(element.get())); 180 } 181 182 static gpointer createAreaWrapper(PassRefPtr<HTMLElement> element) 183 { 184 return wrapHTMLAreaElement(static_cast<HTMLAreaElement*>(element.get())); 185 } 186 187 #if ENABLE(VIDEO) 188 static gpointer createAudioWrapper(PassRefPtr<HTMLElement> element) 189 { 190 return wrapHTMLAudioElement(static_cast<HTMLAudioElement*>(element.get())); 191 } 192 193 static gpointer createVideoWrapper(PassRefPtr<HTMLElement> element) 194 { 195 return wrapHTMLVideoElement(static_cast<HTMLVideoElement*>(element.get())); 196 } 197 #endif 198 199 static gpointer createBaseWrapper(PassRefPtr<HTMLElement> element) 200 { 201 return wrapHTMLBaseElement(static_cast<HTMLBaseElement*>(element.get())); 202 } 203 204 static gpointer createBaseFontWrapper(PassRefPtr<HTMLElement> element) 205 { 206 return wrapHTMLBaseFontElement(static_cast<HTMLBaseFontElement*>(element.get())); 207 } 208 209 static gpointer createBlockquoteWrapper(PassRefPtr<HTMLElement> element) 210 { 211 return wrapHTMLBlockquoteElement(static_cast<HTMLBlockquoteElement*>(element.get())); 212 } 213 214 static gpointer createBodyWrapper(PassRefPtr<HTMLElement> element) 215 { 216 return wrapHTMLBodyElement(static_cast<HTMLBodyElement*>(element.get())); 217 } 218 219 static gpointer createBRWrapper(PassRefPtr<HTMLElement> element) 220 { 221 return wrapHTMLBRElement(static_cast<HTMLBRElement*>(element.get())); 222 } 223 224 static gpointer createButtonWrapper(PassRefPtr<HTMLElement> element) 225 { 226 return wrapHTMLButtonElement(static_cast<HTMLButtonElement*>(element.get())); 227 } 228 229 static gpointer createCanvasWrapper(PassRefPtr<HTMLElement> element) 230 { 231 return wrapHTMLCanvasElement(static_cast<HTMLCanvasElement*>(element.get())); 232 } 233 234 static gpointer createTableCaptionWrapper(PassRefPtr<HTMLElement> element) 235 { 236 return wrapHTMLTableCaptionElement(static_cast<HTMLTableCaptionElement*>(element.get())); 237 } 238 239 static gpointer createTableColWrapper(PassRefPtr<HTMLElement> element) 240 { 241 return wrapHTMLTableColElement(static_cast<HTMLTableColElement*>(element.get())); 242 } 243 244 static gpointer createModWrapper(PassRefPtr<HTMLElement> element) 245 { 246 return wrapHTMLModElement(static_cast<HTMLModElement*>(element.get())); 247 } 248 249 static gpointer createDirectoryWrapper(PassRefPtr<HTMLElement> element) 250 { 251 return wrapHTMLDirectoryElement(static_cast<HTMLDirectoryElement*>(element.get())); 252 } 253 254 static gpointer createDivWrapper(PassRefPtr<HTMLElement> element) 255 { 256 return wrapHTMLDivElement(static_cast<HTMLDivElement*>(element.get())); 257 } 258 259 static gpointer createDListWrapper(PassRefPtr<HTMLElement> element) 260 { 261 return wrapHTMLDListElement(static_cast<HTMLDListElement*>(element.get())); 262 } 263 264 static gpointer createEmbedWrapper(PassRefPtr<HTMLElement> element) 265 { 266 return wrapHTMLEmbedElement(static_cast<HTMLEmbedElement*>(element.get())); 267 } 268 269 static gpointer createFieldSetWrapper(PassRefPtr<HTMLElement> element) 270 { 271 return wrapHTMLFieldSetElement(static_cast<HTMLFieldSetElement*>(element.get())); 272 } 273 274 static gpointer createFontWrapper(PassRefPtr<HTMLElement> element) 275 { 276 return wrapHTMLFontElement(static_cast<HTMLFontElement*>(element.get())); 277 } 278 279 static gpointer createFormWrapper(PassRefPtr<HTMLElement> element) 280 { 281 return wrapHTMLFormElement(static_cast<HTMLFormElement*>(element.get())); 282 } 283 284 static gpointer createFrameWrapper(PassRefPtr<HTMLElement> element) 285 { 286 return wrapHTMLFrameElement(static_cast<HTMLFrameElement*>(element.get())); 287 } 288 289 static gpointer createFrameSetWrapper(PassRefPtr<HTMLElement> element) 290 { 291 return wrapHTMLFrameSetElement(static_cast<HTMLFrameSetElement*>(element.get())); 292 } 293 294 static gpointer createHeadingWrapper(PassRefPtr<HTMLElement> element) 295 { 296 return wrapHTMLHeadingElement(static_cast<HTMLHeadingElement*>(element.get())); 297 } 298 299 static gpointer createHeadWrapper(PassRefPtr<HTMLElement> element) 300 { 301 return wrapHTMLHeadElement(static_cast<HTMLHeadElement*>(element.get())); 302 } 303 304 static gpointer createHRWrapper(PassRefPtr<HTMLElement> element) 305 { 306 return wrapHTMLHRElement(static_cast<HTMLHRElement*>(element.get())); 307 } 308 309 static gpointer createHtmlWrapper(PassRefPtr<HTMLElement> element) 310 { 311 return wrapHTMLHtmlElement(static_cast<HTMLHtmlElement*>(element.get())); 312 } 313 314 static gpointer createIFrameWrapper(PassRefPtr<HTMLElement> element) 315 { 316 return wrapHTMLIFrameElement(static_cast<HTMLIFrameElement*>(element.get())); 317 } 318 319 static gpointer createImageWrapper(PassRefPtr<HTMLElement> element) 320 { 321 return wrapHTMLImageElement(static_cast<HTMLImageElement*>(element.get())); 322 } 323 324 static gpointer createInputWrapper(PassRefPtr<HTMLElement> element) 325 { 326 return wrapHTMLInputElement(static_cast<HTMLInputElement*>(element.get())); 327 } 328 329 static gpointer createIsIndexWrapper(PassRefPtr<HTMLElement> element) 330 { 331 return wrapHTMLIsIndexElement(static_cast<HTMLIsIndexElement*>(element.get())); 332 } 333 334 static gpointer createKeygenWrapper(PassRefPtr<HTMLElement> element) 335 { 336 return wrapHTMLKeygenElement(static_cast<HTMLKeygenElement*>(element.get())); 337 } 338 339 static gpointer createLabelWrapper(PassRefPtr<HTMLElement> element) 340 { 341 return wrapHTMLLabelElement(static_cast<HTMLLabelElement*>(element.get())); 342 } 343 344 static gpointer createLegendWrapper(PassRefPtr<HTMLElement> element) 345 { 346 return wrapHTMLLegendElement(static_cast<HTMLLegendElement*>(element.get())); 347 } 348 349 static gpointer createLIWrapper(PassRefPtr<HTMLElement> element) 350 { 351 return wrapHTMLLIElement(static_cast<HTMLLIElement*>(element.get())); 352 } 353 354 static gpointer createLinkWrapper(PassRefPtr<HTMLElement> element) 355 { 356 return wrapHTMLLinkElement(static_cast<HTMLLinkElement*>(element.get())); 357 } 358 359 static gpointer createMapWrapper(PassRefPtr<HTMLElement> element) 360 { 361 return wrapHTMLMapElement(static_cast<HTMLMapElement*>(element.get())); 362 } 363 364 static gpointer createMarqueeWrapper(PassRefPtr<HTMLElement> element) 365 { 366 return wrapHTMLMarqueeElement(static_cast<HTMLMarqueeElement*>(element.get())); 367 } 368 369 static gpointer createMenuWrapper(PassRefPtr<HTMLElement> element) 370 { 371 return wrapHTMLMenuElement(static_cast<HTMLMenuElement*>(element.get())); 372 } 373 374 static gpointer createMetaWrapper(PassRefPtr<HTMLElement> element) 375 { 376 return wrapHTMLMetaElement(static_cast<HTMLMetaElement*>(element.get())); 377 } 378 379 static gpointer createObjectWrapper(PassRefPtr<HTMLElement> element) 380 { 381 return wrapHTMLObjectElement(static_cast<HTMLObjectElement*>(element.get())); 382 } 383 384 static gpointer createOListWrapper(PassRefPtr<HTMLElement> element) 385 { 386 return wrapHTMLOListElement(static_cast<HTMLOListElement*>(element.get())); 387 } 388 389 static gpointer createOptGroupWrapper(PassRefPtr<HTMLElement> element) 390 { 391 return wrapHTMLOptGroupElement(static_cast<HTMLOptGroupElement*>(element.get())); 392 } 393 394 static gpointer createOptionWrapper(PassRefPtr<HTMLElement> element) 395 { 396 return wrapHTMLOptionElement(static_cast<HTMLOptionElement*>(element.get())); 397 } 398 399 static gpointer createParagraphWrapper(PassRefPtr<HTMLElement> element) 400 { 401 return wrapHTMLParagraphElement(static_cast<HTMLParagraphElement*>(element.get())); 402 } 403 404 static gpointer createParamWrapper(PassRefPtr<HTMLElement> element) 405 { 406 return wrapHTMLParamElement(static_cast<HTMLParamElement*>(element.get())); 407 } 408 409 static gpointer createPreWrapper(PassRefPtr<HTMLElement> element) 410 { 411 return wrapHTMLPreElement(static_cast<HTMLPreElement*>(element.get())); 412 } 413 414 static gpointer createQuoteWrapper(PassRefPtr<HTMLElement> element) 415 { 416 return wrapHTMLQuoteElement(static_cast<HTMLQuoteElement*>(element.get())); 417 } 418 419 static gpointer createScriptWrapper(PassRefPtr<HTMLElement> element) 420 { 421 return wrapHTMLScriptElement(static_cast<HTMLScriptElement*>(element.get())); 422 } 423 424 static gpointer createSelectWrapper(PassRefPtr<HTMLElement> element) 425 { 426 return wrapHTMLSelectElement(static_cast<HTMLSelectElement*>(element.get())); 427 } 428 429 static gpointer createStyleWrapper(PassRefPtr<HTMLElement> element) 430 { 431 return wrapHTMLStyleElement(static_cast<HTMLStyleElement*>(element.get())); 432 } 433 434 static gpointer createTableWrapper(PassRefPtr<HTMLElement> element) 435 { 436 return wrapHTMLTableElement(static_cast<HTMLTableElement*>(element.get())); 437 } 438 439 static gpointer createTableSectionWrapper(PassRefPtr<HTMLElement> element) 440 { 441 return wrapHTMLTableSectionElement(static_cast<HTMLTableSectionElement*>(element.get())); 442 } 443 444 static gpointer createTableCellWrapper(PassRefPtr<HTMLElement> element) 445 { 446 return wrapHTMLTableCellElement(static_cast<HTMLTableCellElement*>(element.get())); 447 } 448 449 static gpointer createTextAreaWrapper(PassRefPtr<HTMLElement> element) 450 { 451 return wrapHTMLTextAreaElement(static_cast<HTMLTextAreaElement*>(element.get())); 452 } 453 454 static gpointer createTitleWrapper(PassRefPtr<HTMLElement> element) 455 { 456 return wrapHTMLTitleElement(static_cast<HTMLTitleElement*>(element.get())); 457 } 458 459 static gpointer createTableRowWrapper(PassRefPtr<HTMLElement> element) 460 { 461 return wrapHTMLTableRowElement(static_cast<HTMLTableRowElement*>(element.get())); 462 } 463 464 static gpointer createUListWrapper(PassRefPtr<HTMLElement> element) 465 { 466 return wrapHTMLUListElement(static_cast<HTMLUListElement*>(element.get())); 467 } 468 469 gpointer createHTMLElementWrapper(PassRefPtr<WebCore::HTMLElement> element) 470 { 471 static HashMap<WTF::AtomicStringImpl*, CreateHTMLElementWrapperFunction> map; 472 if (map.isEmpty()) { 473 map.set(aTag.localName().impl(), createAnchorWrapper); 474 map.set(appletTag.localName().impl(), createAppletWrapper); 475 #if ENABLE(VIDEO) 476 map.set(audioTag.localName().impl(), createAudioWrapper); 477 map.set(videoTag.localName().impl(), createVideoWrapper); 478 #endif 479 map.set(areaTag.localName().impl(), createAreaWrapper); 480 map.set(baseTag.localName().impl(), createBaseWrapper); 481 map.set(basefontTag.localName().impl(), createBaseFontWrapper); 482 map.set(blockquoteTag.localName().impl(), createBlockquoteWrapper); 483 map.set(bodyTag.localName().impl(), createBodyWrapper); 484 map.set(brTag.localName().impl(), createBRWrapper); 485 map.set(buttonTag.localName().impl(), createButtonWrapper); 486 map.set(canvasTag.localName().impl(), createCanvasWrapper); 487 map.set(captionTag.localName().impl(), createTableCaptionWrapper); 488 map.set(colTag.localName().impl(), createTableColWrapper); 489 map.set(delTag.localName().impl(), createModWrapper); 490 map.set(dirTag.localName().impl(), createDirectoryWrapper); 491 map.set(divTag.localName().impl(), createDivWrapper); 492 map.set(dlTag.localName().impl(), createDListWrapper); 493 map.set(embedTag.localName().impl(), createEmbedWrapper); 494 map.set(fieldsetTag.localName().impl(), createFieldSetWrapper); 495 map.set(fontTag.localName().impl(), createFontWrapper); 496 map.set(formTag.localName().impl(), createFormWrapper); 497 map.set(frameTag.localName().impl(), createFrameWrapper); 498 map.set(framesetTag.localName().impl(), createFrameSetWrapper); 499 map.set(h1Tag.localName().impl(), createHeadingWrapper); 500 map.set(headTag.localName().impl(), createHeadWrapper); 501 map.set(hrTag.localName().impl(), createHRWrapper); 502 map.set(htmlTag.localName().impl(), createHtmlWrapper); 503 map.set(iframeTag.localName().impl(), createIFrameWrapper); 504 map.set(imgTag.localName().impl(), createImageWrapper); 505 map.set(inputTag.localName().impl(), createInputWrapper); 506 map.set(isindexTag.localName().impl(), createIsIndexWrapper); 507 map.set(labelTag.localName().impl(), createLabelWrapper); 508 map.set(legendTag.localName().impl(), createLegendWrapper); 509 map.set(liTag.localName().impl(), createLIWrapper); 510 map.set(linkTag.localName().impl(), createLinkWrapper); 511 map.set(mapTag.localName().impl(), createMapWrapper); 512 map.set(marqueeTag.localName().impl(), createMarqueeWrapper); 513 map.set(menuTag.localName().impl(), createMenuWrapper); 514 map.set(metaTag.localName().impl(), createMetaWrapper); 515 map.set(objectTag.localName().impl(), createObjectWrapper); 516 map.set(olTag.localName().impl(), createOListWrapper); 517 map.set(optgroupTag.localName().impl(), createOptGroupWrapper); 518 map.set(optionTag.localName().impl(), createOptionWrapper); 519 map.set(pTag.localName().impl(), createParagraphWrapper); 520 map.set(paramTag.localName().impl(), createParamWrapper); 521 map.set(preTag.localName().impl(), createPreWrapper); 522 map.set(qTag.localName().impl(), createQuoteWrapper); 523 map.set(scriptTag.localName().impl(), createScriptWrapper); 524 map.set(selectTag.localName().impl(), createSelectWrapper); 525 map.set(styleTag.localName().impl(), createStyleWrapper); 526 map.set(tableTag.localName().impl(), createTableWrapper); 527 map.set(tbodyTag.localName().impl(), createTableSectionWrapper); 528 map.set(tdTag.localName().impl(), createTableCellWrapper); 529 map.set(textareaTag.localName().impl(), createTextAreaWrapper); 530 map.set(titleTag.localName().impl(), createTitleWrapper); 531 map.set(trTag.localName().impl(), createTableRowWrapper); 532 map.set(ulTag.localName().impl(), createUListWrapper); 533 map.set(colgroupTag.localName().impl(), createTableColWrapper); 534 map.set(h2Tag.localName().impl(), createHeadingWrapper); 535 map.set(h3Tag.localName().impl(), createHeadingWrapper); 536 map.set(h4Tag.localName().impl(), createHeadingWrapper); 537 map.set(h5Tag.localName().impl(), createHeadingWrapper); 538 map.set(h6Tag.localName().impl(), createHeadingWrapper); 539 map.set(imageTag.localName().impl(), createImageWrapper); 540 map.set(insTag.localName().impl(), createModWrapper); 541 map.set(keygenTag.localName().impl(), createKeygenWrapper); 542 map.set(listingTag.localName().impl(), createPreWrapper); 543 map.set(tfootTag.localName().impl(), createTableSectionWrapper); 544 map.set(thTag.localName().impl(), createTableCellWrapper); 545 map.set(theadTag.localName().impl(), createTableSectionWrapper); 546 map.set(xmpTag.localName().impl(), createPreWrapper); 547 } 548 549 CreateHTMLElementWrapperFunction createWrapperFunction = 550 map.get(element->localName().impl()); 551 if (createWrapperFunction) 552 return createWrapperFunction(element); 553 return wrapHTMLElement(element.get()); 554 } 555 556 } 557