1 /* 2 * Copyright (C) 2006, 2007 Apple Inc. All rights reserved. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions 6 * are met: 7 * 1. Redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer. 9 * 2. Redistributions in binary form must reproduce the above copyright 10 * notice, this list of conditions and the following disclaimer in the 11 * documentation and/or other materials provided with the distribution. 12 * 13 * THIS SOFTWARE IS PROVIDED BY APPLE COMPUTER, INC. ``AS IS'' AND ANY 14 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 15 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 16 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE COMPUTER, INC. OR 17 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 18 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 19 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 20 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY 21 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 23 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 */ 25 26 #ifndef DOMEventsClasses_H 27 #define DOMEventsClasses_H 28 29 #include "WebKit.h" 30 #include "DOMCoreClasses.h" 31 32 #include <wtf/PassRefPtr.h> 33 #include <wtf/RefPtr.h> 34 35 // {AC3D1BC3-4976-4431-8A19-4812C5EFE39C} 36 DEFINE_GUID(IID_DOMEvent, 0xac3d1bc3, 0x4976, 0x4431, 0x8a, 0x19, 0x48, 0x12, 0xc5, 0xef, 0xe3, 0x9c); 37 38 namespace WebCore { 39 class Event; 40 } 41 42 class DOMUIEvent; 43 44 class DOMEventListener : public DOMObject, public IDOMEventListener 45 { 46 public: 47 // IUnknown 48 virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, void** ppvObject); AddRef(void)49 virtual ULONG STDMETHODCALLTYPE AddRef(void) { return DOMObject::AddRef(); } Release(void)50 virtual ULONG STDMETHODCALLTYPE Release(void) { return DOMObject::Release(); } 51 52 // IWebScriptObject throwException(BSTR exceptionMessage,BOOL * result)53 virtual HRESULT STDMETHODCALLTYPE throwException( 54 /* [in] */ BSTR exceptionMessage, 55 /* [retval][out] */ BOOL* result) { return DOMObject::throwException(exceptionMessage, result); } 56 callWebScriptMethod(BSTR name,const VARIANT args[],int cArgs,VARIANT * result)57 virtual HRESULT STDMETHODCALLTYPE callWebScriptMethod( 58 /* [in] */ BSTR name, 59 /* [size_is][in] */ const VARIANT args[ ], 60 /* [in] */ int cArgs, 61 /* [retval][out] */ VARIANT* result) { return DOMObject::callWebScriptMethod(name, args, cArgs, result); } 62 evaluateWebScript(BSTR script,VARIANT * result)63 virtual HRESULT STDMETHODCALLTYPE evaluateWebScript( 64 /* [in] */ BSTR script, 65 /* [retval][out] */ VARIANT* result) { return DOMObject::evaluateWebScript(script, result); } 66 removeWebScriptKey(BSTR name)67 virtual HRESULT STDMETHODCALLTYPE removeWebScriptKey( 68 /* [in] */ BSTR name) { return DOMObject::removeWebScriptKey(name); } 69 stringRepresentation(BSTR * stringRepresentation)70 virtual HRESULT STDMETHODCALLTYPE stringRepresentation( 71 /* [retval][out] */ BSTR* stringRepresentation) { return DOMObject::stringRepresentation(stringRepresentation); } 72 webScriptValueAtIndex(unsigned int index,VARIANT * result)73 virtual HRESULT STDMETHODCALLTYPE webScriptValueAtIndex( 74 /* [in] */ unsigned int index, 75 /* [retval][out] */ VARIANT* result) { return DOMObject::webScriptValueAtIndex(index, result); } 76 setWebScriptValueAtIndex(unsigned int index,VARIANT val)77 virtual HRESULT STDMETHODCALLTYPE setWebScriptValueAtIndex( 78 /* [in] */ unsigned int index, 79 /* [in] */ VARIANT val) { return DOMObject::setWebScriptValueAtIndex(index, val); } 80 setException(BSTR description)81 virtual HRESULT STDMETHODCALLTYPE setException( 82 /* [in] */ BSTR description) { return DOMObject::setException(description); } 83 84 // IDOMEventListener 85 virtual HRESULT STDMETHODCALLTYPE handleEvent( 86 /* [in] */ IDOMEvent* evt); 87 }; 88 89 class DOMEvent : public DOMObject, public IDOMEvent 90 { 91 public: 92 static IDOMEvent* createInstance(PassRefPtr<WebCore::Event> e); 93 protected: 94 DOMEvent(PassRefPtr<WebCore::Event> e); 95 ~DOMEvent(); 96 97 public: 98 // IUnknown 99 virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, void** ppvObject); AddRef(void)100 virtual ULONG STDMETHODCALLTYPE AddRef(void) { return DOMObject::AddRef(); } Release(void)101 virtual ULONG STDMETHODCALLTYPE Release(void) { return DOMObject::Release(); } 102 103 // IWebScriptObject throwException(BSTR exceptionMessage,BOOL * result)104 virtual HRESULT STDMETHODCALLTYPE throwException( 105 /* [in] */ BSTR exceptionMessage, 106 /* [retval][out] */ BOOL* result) { return DOMObject::throwException(exceptionMessage, result); } 107 callWebScriptMethod(BSTR name,const VARIANT args[],int cArgs,VARIANT * result)108 virtual HRESULT STDMETHODCALLTYPE callWebScriptMethod( 109 /* [in] */ BSTR name, 110 /* [size_is][in] */ const VARIANT args[ ], 111 /* [in] */ int cArgs, 112 /* [retval][out] */ VARIANT* result) { return DOMObject::callWebScriptMethod(name, args, cArgs, result); } 113 evaluateWebScript(BSTR script,VARIANT * result)114 virtual HRESULT STDMETHODCALLTYPE evaluateWebScript( 115 /* [in] */ BSTR script, 116 /* [retval][out] */ VARIANT* result) { return DOMObject::evaluateWebScript(script, result); } 117 removeWebScriptKey(BSTR name)118 virtual HRESULT STDMETHODCALLTYPE removeWebScriptKey( 119 /* [in] */ BSTR name) { return DOMObject::removeWebScriptKey(name); } 120 stringRepresentation(BSTR * stringRepresentation)121 virtual HRESULT STDMETHODCALLTYPE stringRepresentation( 122 /* [retval][out] */ BSTR* stringRepresentation) { return DOMObject::stringRepresentation(stringRepresentation); } 123 webScriptValueAtIndex(unsigned int index,VARIANT * result)124 virtual HRESULT STDMETHODCALLTYPE webScriptValueAtIndex( 125 /* [in] */ unsigned int index, 126 /* [retval][out] */ VARIANT* result) { return DOMObject::webScriptValueAtIndex(index, result); } 127 setWebScriptValueAtIndex(unsigned int index,VARIANT val)128 virtual HRESULT STDMETHODCALLTYPE setWebScriptValueAtIndex( 129 /* [in] */ unsigned int index, 130 /* [in] */ VARIANT val) { return DOMObject::setWebScriptValueAtIndex(index, val); } 131 setException(BSTR description)132 virtual HRESULT STDMETHODCALLTYPE setException( 133 /* [in] */ BSTR description) { return DOMObject::setException(description); } 134 135 // IDOMEvent 136 virtual HRESULT STDMETHODCALLTYPE type( 137 /* [retval][out] */ BSTR* result); 138 139 virtual HRESULT STDMETHODCALLTYPE target( 140 /* [retval][out] */ IDOMEventTarget** result); 141 142 virtual HRESULT STDMETHODCALLTYPE currentTarget( 143 /* [retval][out] */ IDOMEventTarget** result); 144 145 virtual HRESULT STDMETHODCALLTYPE eventPhase( 146 /* [retval][out] */ unsigned short* result); 147 148 virtual HRESULT STDMETHODCALLTYPE bubbles( 149 /* [retval][out] */ BOOL* result); 150 151 virtual HRESULT STDMETHODCALLTYPE cancelable( 152 /* [retval][out] */ BOOL* result); 153 154 virtual HRESULT STDMETHODCALLTYPE timeStamp( 155 /* [retval][out] */ DOMTimeStamp* result); 156 157 virtual HRESULT STDMETHODCALLTYPE stopPropagation( void); 158 159 virtual HRESULT STDMETHODCALLTYPE preventDefault( void); 160 161 virtual HRESULT STDMETHODCALLTYPE initEvent( 162 /* [in] */ BSTR eventTypeArg, 163 /* [in] */ BOOL canBubbleArg, 164 /* [in] */ BOOL cancelableArg); 165 166 // DOMEvent methods coreEvent()167 WebCore::Event* coreEvent() { return m_event.get(); } 168 169 protected: 170 RefPtr<WebCore::Event> m_event; 171 }; 172 173 class DOMUIEvent : public DOMEvent, public IDOMUIEvent 174 { 175 public: DOMUIEvent(PassRefPtr<WebCore::Event> e)176 DOMUIEvent(PassRefPtr<WebCore::Event> e) : DOMEvent(e) {} 177 178 // IUnknown 179 virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, void** ppvObject); AddRef(void)180 virtual ULONG STDMETHODCALLTYPE AddRef(void) { return DOMEvent::AddRef(); } Release(void)181 virtual ULONG STDMETHODCALLTYPE Release(void) { return DOMEvent::Release(); } 182 183 // IWebScriptObject throwException(BSTR exceptionMessage,BOOL * result)184 virtual HRESULT STDMETHODCALLTYPE throwException( 185 /* [in] */ BSTR exceptionMessage, 186 /* [retval][out] */ BOOL* result) { return DOMObject::throwException(exceptionMessage, result); } 187 callWebScriptMethod(BSTR name,const VARIANT args[],int cArgs,VARIANT * result)188 virtual HRESULT STDMETHODCALLTYPE callWebScriptMethod( 189 /* [in] */ BSTR name, 190 /* [size_is][in] */ const VARIANT args[ ], 191 /* [in] */ int cArgs, 192 /* [retval][out] */ VARIANT* result) { return DOMObject::callWebScriptMethod(name, args, cArgs, result); } 193 evaluateWebScript(BSTR script,VARIANT * result)194 virtual HRESULT STDMETHODCALLTYPE evaluateWebScript( 195 /* [in] */ BSTR script, 196 /* [retval][out] */ VARIANT* result) { return DOMObject::evaluateWebScript(script, result); } 197 removeWebScriptKey(BSTR name)198 virtual HRESULT STDMETHODCALLTYPE removeWebScriptKey( 199 /* [in] */ BSTR name) { return DOMObject::removeWebScriptKey(name); } 200 stringRepresentation(BSTR * stringRepresentation)201 virtual HRESULT STDMETHODCALLTYPE stringRepresentation( 202 /* [retval][out] */ BSTR* stringRepresentation) { return DOMObject::stringRepresentation(stringRepresentation); } 203 webScriptValueAtIndex(unsigned int index,VARIANT * result)204 virtual HRESULT STDMETHODCALLTYPE webScriptValueAtIndex( 205 /* [in] */ unsigned int index, 206 /* [retval][out] */ VARIANT* result) { return DOMObject::webScriptValueAtIndex(index, result); } 207 setWebScriptValueAtIndex(unsigned int index,VARIANT val)208 virtual HRESULT STDMETHODCALLTYPE setWebScriptValueAtIndex( 209 /* [in] */ unsigned int index, 210 /* [in] */ VARIANT val) { return DOMObject::setWebScriptValueAtIndex(index, val); } 211 setException(BSTR description)212 virtual HRESULT STDMETHODCALLTYPE setException( 213 /* [in] */ BSTR description) { return DOMObject::setException(description); } 214 215 // IDOMEvent type(BSTR * result)216 virtual HRESULT STDMETHODCALLTYPE type( 217 /* [retval][out] */ BSTR* result) { return DOMEvent::type(result); } 218 target(IDOMEventTarget ** result)219 virtual HRESULT STDMETHODCALLTYPE target( 220 /* [retval][out] */ IDOMEventTarget** result) { return DOMEvent::target(result); } 221 currentTarget(IDOMEventTarget ** result)222 virtual HRESULT STDMETHODCALLTYPE currentTarget( 223 /* [retval][out] */ IDOMEventTarget** result) { return DOMEvent::currentTarget(result); } 224 eventPhase(unsigned short * result)225 virtual HRESULT STDMETHODCALLTYPE eventPhase( 226 /* [retval][out] */ unsigned short* result) { return DOMEvent::eventPhase(result); } 227 bubbles(BOOL * result)228 virtual HRESULT STDMETHODCALLTYPE bubbles( 229 /* [retval][out] */ BOOL* result) { return DOMEvent::bubbles(result); } 230 cancelable(BOOL * result)231 virtual HRESULT STDMETHODCALLTYPE cancelable( 232 /* [retval][out] */ BOOL* result) { return DOMEvent::cancelable(result); } 233 timeStamp(DOMTimeStamp * result)234 virtual HRESULT STDMETHODCALLTYPE timeStamp( 235 /* [retval][out] */ DOMTimeStamp* result) { return DOMEvent::timeStamp(result); } 236 stopPropagation(void)237 virtual HRESULT STDMETHODCALLTYPE stopPropagation( void) { return DOMEvent::stopPropagation(); } 238 preventDefault(void)239 virtual HRESULT STDMETHODCALLTYPE preventDefault( void) { return DOMEvent::preventDefault(); } 240 initEvent(BSTR eventTypeArg,BOOL canBubbleArg,BOOL cancelableArg)241 virtual HRESULT STDMETHODCALLTYPE initEvent( 242 /* [in] */ BSTR eventTypeArg, 243 /* [in] */ BOOL canBubbleArg, 244 /* [in] */ BOOL cancelableArg) { return DOMEvent::initEvent(eventTypeArg, canBubbleArg, cancelableArg); } 245 246 // IDOMUIEvent 247 virtual HRESULT STDMETHODCALLTYPE view( 248 /* [retval][out] */ IDOMWindow** result); 249 250 virtual HRESULT STDMETHODCALLTYPE detail( 251 /* [retval][out] */ long* result); 252 253 virtual HRESULT STDMETHODCALLTYPE initUIEvent( 254 /* [in] */ BSTR type, 255 /* [in] */ BOOL canBubble, 256 /* [in] */ BOOL cancelable, 257 /* [in] */ IDOMWindow* view, 258 /* [in] */ long detail); 259 260 virtual HRESULT STDMETHODCALLTYPE keyCode( 261 /* [retval][out] */ long* result); 262 263 virtual HRESULT STDMETHODCALLTYPE charCode( 264 /* [retval][out] */ long* result); 265 266 virtual HRESULT STDMETHODCALLTYPE layerX( 267 /* [retval][out] */ long* result); 268 269 virtual HRESULT STDMETHODCALLTYPE layerY( 270 /* [retval][out] */ long* result); 271 272 virtual HRESULT STDMETHODCALLTYPE pageX( 273 /* [retval][out] */ long* result); 274 275 virtual HRESULT STDMETHODCALLTYPE pageY( 276 /* [retval][out] */ long* result); 277 278 virtual HRESULT STDMETHODCALLTYPE which( 279 /* [retval][out] */ long* result); 280 }; 281 282 class DOMKeyboardEvent : public DOMUIEvent, public IDOMKeyboardEvent 283 { 284 public: DOMKeyboardEvent(PassRefPtr<WebCore::Event> e)285 DOMKeyboardEvent(PassRefPtr<WebCore::Event> e) : DOMUIEvent(e) { } 286 287 // IUnknown 288 virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, void** ppvObject); AddRef(void)289 virtual ULONG STDMETHODCALLTYPE AddRef(void) { return DOMUIEvent::AddRef(); } Release(void)290 virtual ULONG STDMETHODCALLTYPE Release(void) { return DOMUIEvent::Release(); } 291 292 // IWebScriptObject throwException(BSTR exceptionMessage,BOOL * result)293 virtual HRESULT STDMETHODCALLTYPE throwException( 294 /* [in] */ BSTR exceptionMessage, 295 /* [retval][out] */ BOOL* result) { return DOMObject::throwException(exceptionMessage, result); } 296 callWebScriptMethod(BSTR name,const VARIANT args[],int cArgs,VARIANT * result)297 virtual HRESULT STDMETHODCALLTYPE callWebScriptMethod( 298 /* [in] */ BSTR name, 299 /* [size_is][in] */ const VARIANT args[ ], 300 /* [in] */ int cArgs, 301 /* [retval][out] */ VARIANT* result) { return DOMObject::callWebScriptMethod(name, args, cArgs, result); } 302 evaluateWebScript(BSTR script,VARIANT * result)303 virtual HRESULT STDMETHODCALLTYPE evaluateWebScript( 304 /* [in] */ BSTR script, 305 /* [retval][out] */ VARIANT* result) { return DOMObject::evaluateWebScript(script, result); } 306 removeWebScriptKey(BSTR name)307 virtual HRESULT STDMETHODCALLTYPE removeWebScriptKey( 308 /* [in] */ BSTR name) { return DOMObject::removeWebScriptKey(name); } 309 stringRepresentation(BSTR * stringRepresentation)310 virtual HRESULT STDMETHODCALLTYPE stringRepresentation( 311 /* [retval][out] */ BSTR* stringRepresentation) { return DOMObject::stringRepresentation(stringRepresentation); } 312 webScriptValueAtIndex(unsigned int index,VARIANT * result)313 virtual HRESULT STDMETHODCALLTYPE webScriptValueAtIndex( 314 /* [in] */ unsigned int index, 315 /* [retval][out] */ VARIANT* result) { return DOMObject::webScriptValueAtIndex(index, result); } 316 setWebScriptValueAtIndex(unsigned int index,VARIANT val)317 virtual HRESULT STDMETHODCALLTYPE setWebScriptValueAtIndex( 318 /* [in] */ unsigned int index, 319 /* [in] */ VARIANT val) { return DOMObject::setWebScriptValueAtIndex(index, val); } 320 setException(BSTR description)321 virtual HRESULT STDMETHODCALLTYPE setException( 322 /* [in] */ BSTR description) { return DOMObject::setException(description); } 323 324 // IDOMEvent type(BSTR * result)325 virtual HRESULT STDMETHODCALLTYPE type( 326 /* [retval][out] */ BSTR* result) { return DOMEvent::type(result); } 327 target(IDOMEventTarget ** result)328 virtual HRESULT STDMETHODCALLTYPE target( 329 /* [retval][out] */ IDOMEventTarget** result) { return DOMEvent::target(result); } 330 currentTarget(IDOMEventTarget ** result)331 virtual HRESULT STDMETHODCALLTYPE currentTarget( 332 /* [retval][out] */ IDOMEventTarget** result) { return DOMEvent::currentTarget(result); } 333 eventPhase(unsigned short * result)334 virtual HRESULT STDMETHODCALLTYPE eventPhase( 335 /* [retval][out] */ unsigned short* result) { return DOMEvent::eventPhase(result); } 336 bubbles(BOOL * result)337 virtual HRESULT STDMETHODCALLTYPE bubbles( 338 /* [retval][out] */ BOOL* result) { return DOMEvent::bubbles(result); } 339 cancelable(BOOL * result)340 virtual HRESULT STDMETHODCALLTYPE cancelable( 341 /* [retval][out] */ BOOL* result) { return DOMEvent::cancelable(result); } 342 timeStamp(DOMTimeStamp * result)343 virtual HRESULT STDMETHODCALLTYPE timeStamp( 344 /* [retval][out] */ DOMTimeStamp* result) { return DOMEvent::timeStamp(result); } 345 stopPropagation(void)346 virtual HRESULT STDMETHODCALLTYPE stopPropagation( void) { return DOMEvent::stopPropagation(); } 347 preventDefault(void)348 virtual HRESULT STDMETHODCALLTYPE preventDefault( void) { return DOMEvent::preventDefault(); } 349 initEvent(BSTR eventTypeArg,BOOL canBubbleArg,BOOL cancelableArg)350 virtual HRESULT STDMETHODCALLTYPE initEvent( 351 /* [in] */ BSTR eventTypeArg, 352 /* [in] */ BOOL canBubbleArg, 353 /* [in] */ BOOL cancelableArg) { return DOMEvent::initEvent(eventTypeArg, canBubbleArg, cancelableArg); } 354 355 // IDOMUIEvent view(IDOMWindow ** result)356 virtual HRESULT STDMETHODCALLTYPE view( 357 /* [retval][out] */ IDOMWindow** result) { return DOMUIEvent::view(result); } 358 detail(long * result)359 virtual HRESULT STDMETHODCALLTYPE detail( 360 /* [retval][out] */ long* result) { return DOMUIEvent::detail(result); } 361 initUIEvent(BSTR type,BOOL canBubble,BOOL cancelable,IDOMWindow * view,long detail)362 virtual HRESULT STDMETHODCALLTYPE initUIEvent( 363 /* [in] */ BSTR type, 364 /* [in] */ BOOL canBubble, 365 /* [in] */ BOOL cancelable, 366 /* [in] */ IDOMWindow* view, 367 /* [in] */ long detail) { return DOMUIEvent::initUIEvent(type, canBubble, cancelable, view, detail); } 368 keyCode(long * result)369 virtual HRESULT STDMETHODCALLTYPE keyCode( 370 /* [retval][out] */ long* result) { return DOMUIEvent::keyCode(result); } 371 charCode(long * result)372 virtual HRESULT STDMETHODCALLTYPE charCode( 373 /* [retval][out] */ long* result) { return DOMUIEvent::charCode(result); } 374 layerX(long * result)375 virtual HRESULT STDMETHODCALLTYPE layerX( 376 /* [retval][out] */ long* result) { return DOMUIEvent::layerX(result); } 377 layerY(long * result)378 virtual HRESULT STDMETHODCALLTYPE layerY( 379 /* [retval][out] */ long* result) { return DOMUIEvent::layerY(result); } 380 pageX(long * result)381 virtual HRESULT STDMETHODCALLTYPE pageX( 382 /* [retval][out] */ long* result) { return DOMUIEvent::pageX(result); } 383 pageY(long * result)384 virtual HRESULT STDMETHODCALLTYPE pageY( 385 /* [retval][out] */ long* result) { return DOMUIEvent::pageY(result); } 386 which(long * result)387 virtual HRESULT STDMETHODCALLTYPE which( 388 /* [retval][out] */ long* result) { return DOMUIEvent::which(result); } 389 390 // IDOMKeyboardEvent 391 virtual HRESULT STDMETHODCALLTYPE keyIdentifier( 392 /* [retval][out] */ BSTR* result); 393 394 virtual HRESULT STDMETHODCALLTYPE keyLocation( 395 /* [retval][out] */ unsigned long* result); 396 397 virtual HRESULT STDMETHODCALLTYPE ctrlKey( 398 /* [retval][out] */ BOOL* result); 399 400 virtual HRESULT STDMETHODCALLTYPE shiftKey( 401 /* [retval][out] */ BOOL* result); 402 403 virtual HRESULT STDMETHODCALLTYPE altKey( 404 /* [retval][out] */ BOOL* result); 405 406 virtual HRESULT STDMETHODCALLTYPE metaKey( 407 /* [retval][out] */ BOOL* result); 408 409 virtual HRESULT STDMETHODCALLTYPE altGraphKey( 410 /* [retval][out] */ BOOL* result); 411 412 virtual HRESULT STDMETHODCALLTYPE getModifierState( 413 /* [in] */ BSTR keyIdentifierArg, 414 /* [retval][out] */ BOOL* result); 415 416 virtual HRESULT STDMETHODCALLTYPE initKeyboardEvent( 417 /* [in] */ BSTR type, 418 /* [in] */ BOOL canBubble, 419 /* [in] */ BOOL cancelable, 420 /* [in] */ IDOMWindow* view, 421 /* [in] */ BSTR keyIdentifier, 422 /* [in] */ unsigned long keyLocation, 423 /* [in] */ BOOL ctrlKey, 424 /* [in] */ BOOL altKey, 425 /* [in] */ BOOL shiftKey, 426 /* [in] */ BOOL metaKey, 427 /* [in] */ BOOL graphKey); 428 }; 429 430 class DOMMouseEvent : public DOMUIEvent, public IDOMMouseEvent 431 { 432 public: DOMMouseEvent(PassRefPtr<WebCore::Event> e)433 DOMMouseEvent(PassRefPtr<WebCore::Event> e) : DOMUIEvent(e) { } 434 435 // IUnknown 436 virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, void** ppvObject); AddRef(void)437 virtual ULONG STDMETHODCALLTYPE AddRef(void) { return DOMUIEvent::AddRef(); } Release(void)438 virtual ULONG STDMETHODCALLTYPE Release(void) { return DOMUIEvent::Release(); } 439 440 // IWebScriptObject throwException(BSTR exceptionMessage,BOOL * result)441 virtual HRESULT STDMETHODCALLTYPE throwException( 442 /* [in] */ BSTR exceptionMessage, 443 /* [retval][out] */ BOOL* result) { return DOMObject::throwException(exceptionMessage, result); } 444 callWebScriptMethod(BSTR name,const VARIANT args[],int cArgs,VARIANT * result)445 virtual HRESULT STDMETHODCALLTYPE callWebScriptMethod( 446 /* [in] */ BSTR name, 447 /* [size_is][in] */ const VARIANT args[ ], 448 /* [in] */ int cArgs, 449 /* [retval][out] */ VARIANT* result) { return DOMObject::callWebScriptMethod(name, args, cArgs, result); } 450 evaluateWebScript(BSTR script,VARIANT * result)451 virtual HRESULT STDMETHODCALLTYPE evaluateWebScript( 452 /* [in] */ BSTR script, 453 /* [retval][out] */ VARIANT* result) { return DOMObject::evaluateWebScript(script, result); } 454 removeWebScriptKey(BSTR name)455 virtual HRESULT STDMETHODCALLTYPE removeWebScriptKey( 456 /* [in] */ BSTR name) { return DOMObject::removeWebScriptKey(name); } 457 stringRepresentation(BSTR * stringRepresentation)458 virtual HRESULT STDMETHODCALLTYPE stringRepresentation( 459 /* [retval][out] */ BSTR* stringRepresentation) { return DOMObject::stringRepresentation(stringRepresentation); } 460 webScriptValueAtIndex(unsigned int index,VARIANT * result)461 virtual HRESULT STDMETHODCALLTYPE webScriptValueAtIndex( 462 /* [in] */ unsigned int index, 463 /* [retval][out] */ VARIANT* result) { return DOMObject::webScriptValueAtIndex(index, result); } 464 setWebScriptValueAtIndex(unsigned int index,VARIANT val)465 virtual HRESULT STDMETHODCALLTYPE setWebScriptValueAtIndex( 466 /* [in] */ unsigned int index, 467 /* [in] */ VARIANT val) { return DOMObject::setWebScriptValueAtIndex(index, val); } 468 setException(BSTR description)469 virtual HRESULT STDMETHODCALLTYPE setException( 470 /* [in] */ BSTR description) { return DOMObject::setException(description); } 471 472 // IDOMEvent type(BSTR * result)473 virtual HRESULT STDMETHODCALLTYPE type( 474 /* [retval][out] */ BSTR* result) { return DOMEvent::type(result); } 475 target(IDOMEventTarget ** result)476 virtual HRESULT STDMETHODCALLTYPE target( 477 /* [retval][out] */ IDOMEventTarget** result) { return DOMEvent::target(result); } 478 currentTarget(IDOMEventTarget ** result)479 virtual HRESULT STDMETHODCALLTYPE currentTarget( 480 /* [retval][out] */ IDOMEventTarget** result) { return DOMEvent::currentTarget(result); } 481 eventPhase(unsigned short * result)482 virtual HRESULT STDMETHODCALLTYPE eventPhase( 483 /* [retval][out] */ unsigned short* result) { return DOMEvent::eventPhase(result); } 484 bubbles(BOOL * result)485 virtual HRESULT STDMETHODCALLTYPE bubbles( 486 /* [retval][out] */ BOOL* result) { return DOMEvent::bubbles(result); } 487 cancelable(BOOL * result)488 virtual HRESULT STDMETHODCALLTYPE cancelable( 489 /* [retval][out] */ BOOL* result) { return DOMEvent::cancelable(result); } 490 timeStamp(DOMTimeStamp * result)491 virtual HRESULT STDMETHODCALLTYPE timeStamp( 492 /* [retval][out] */ DOMTimeStamp* result) { return DOMEvent::timeStamp(result); } 493 stopPropagation(void)494 virtual HRESULT STDMETHODCALLTYPE stopPropagation( void) { return DOMEvent::stopPropagation(); } 495 preventDefault(void)496 virtual HRESULT STDMETHODCALLTYPE preventDefault( void) { return DOMEvent::preventDefault(); } 497 initEvent(BSTR eventTypeArg,BOOL canBubbleArg,BOOL cancelableArg)498 virtual HRESULT STDMETHODCALLTYPE initEvent( 499 /* [in] */ BSTR eventTypeArg, 500 /* [in] */ BOOL canBubbleArg, 501 /* [in] */ BOOL cancelableArg) { return DOMEvent::initEvent(eventTypeArg, canBubbleArg, cancelableArg); } 502 503 // IDOMUIEvent view(IDOMWindow ** result)504 virtual HRESULT STDMETHODCALLTYPE view( 505 /* [retval][out] */ IDOMWindow** result) { return DOMUIEvent::view(result); } 506 detail(long * result)507 virtual HRESULT STDMETHODCALLTYPE detail( 508 /* [retval][out] */ long* result) { return DOMUIEvent::detail(result); } 509 initUIEvent(BSTR type,BOOL canBubble,BOOL cancelable,IDOMWindow * view,long detail)510 virtual HRESULT STDMETHODCALLTYPE initUIEvent( 511 /* [in] */ BSTR type, 512 /* [in] */ BOOL canBubble, 513 /* [in] */ BOOL cancelable, 514 /* [in] */ IDOMWindow* view, 515 /* [in] */ long detail) { return DOMUIEvent::initUIEvent(type, canBubble, cancelable, view, detail); } 516 keyCode(long * result)517 virtual HRESULT STDMETHODCALLTYPE keyCode( 518 /* [retval][out] */ long* result) { return DOMUIEvent::keyCode(result); } 519 charCode(long * result)520 virtual HRESULT STDMETHODCALLTYPE charCode( 521 /* [retval][out] */ long* result) { return DOMUIEvent::charCode(result); } 522 layerX(long * result)523 virtual HRESULT STDMETHODCALLTYPE layerX( 524 /* [retval][out] */ long* result) { return DOMUIEvent::layerX(result); } 525 layerY(long * result)526 virtual HRESULT STDMETHODCALLTYPE layerY( 527 /* [retval][out] */ long* result) { return DOMUIEvent::layerY(result); } 528 pageX(long * result)529 virtual HRESULT STDMETHODCALLTYPE pageX( 530 /* [retval][out] */ long* result) { return DOMUIEvent::pageX(result); } 531 pageY(long * result)532 virtual HRESULT STDMETHODCALLTYPE pageY( 533 /* [retval][out] */ long* result) { return DOMUIEvent::pageY(result); } 534 which(long * result)535 virtual HRESULT STDMETHODCALLTYPE which( 536 /* [retval][out] */ long* result) { return DOMUIEvent::which(result); } 537 538 // IDOMMouseEvent 539 virtual HRESULT STDMETHODCALLTYPE screenX( 540 /* [retval][out] */ long* result); 541 542 virtual HRESULT STDMETHODCALLTYPE screenY( 543 /* [retval][out] */ long* result); 544 545 virtual HRESULT STDMETHODCALLTYPE clientX( 546 /* [retval][out] */ long* result); 547 548 virtual HRESULT STDMETHODCALLTYPE clientY( 549 /* [retval][out] */ long* result); 550 551 virtual HRESULT STDMETHODCALLTYPE ctrlKey( 552 /* [retval][out] */ BOOL* result); 553 554 virtual HRESULT STDMETHODCALLTYPE shiftKey( 555 /* [retval][out] */ BOOL* result); 556 557 virtual HRESULT STDMETHODCALLTYPE altKey( 558 /* [retval][out] */ BOOL* result); 559 560 virtual HRESULT STDMETHODCALLTYPE metaKey( 561 /* [retval][out] */ BOOL* result); 562 563 virtual HRESULT STDMETHODCALLTYPE button( 564 /* [retval][out] */ unsigned short* result); 565 566 virtual HRESULT STDMETHODCALLTYPE relatedTarget( 567 /* [retval][out] */ IDOMEventTarget** result); 568 569 virtual HRESULT STDMETHODCALLTYPE initMouseEvent( 570 /* [in] */ BSTR type, 571 /* [in] */ BOOL canBubble, 572 /* [in] */ BOOL cancelable, 573 /* [in] */ IDOMWindow* view, 574 /* [in] */ long detail, 575 /* [in] */ long screenX, 576 /* [in] */ long screenY, 577 /* [in] */ long clientX, 578 /* [in] */ long clientY, 579 /* [in] */ BOOL ctrlKey, 580 /* [in] */ BOOL altKey, 581 /* [in] */ BOOL shiftKey, 582 /* [in] */ BOOL metaKey, 583 /* [in] */ unsigned short button, 584 /* [in] */ IDOMEventTarget* relatedTarget); 585 586 virtual HRESULT STDMETHODCALLTYPE offsetX( 587 /* [retval][out] */ long* result); 588 589 virtual HRESULT STDMETHODCALLTYPE offsetY( 590 /* [retval][out] */ long* result); 591 592 virtual HRESULT STDMETHODCALLTYPE x( 593 /* [retval][out] */ long* result); 594 595 virtual HRESULT STDMETHODCALLTYPE y( 596 /* [retval][out] */ long* result); 597 598 virtual HRESULT STDMETHODCALLTYPE fromElement( 599 /* [retval][out] */ IDOMNode** result); 600 601 virtual HRESULT STDMETHODCALLTYPE toElement( 602 /* [retval][out] */ IDOMNode** result); 603 }; 604 605 class DOMMutationEvent : public DOMEvent, public IDOMMutationEvent 606 { 607 public: DOMMutationEvent(PassRefPtr<WebCore::Event> e)608 DOMMutationEvent(PassRefPtr<WebCore::Event> e) : DOMEvent(e) { } 609 610 // IUnknown 611 virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, void** ppvObject); AddRef(void)612 virtual ULONG STDMETHODCALLTYPE AddRef(void) { return DOMEvent::AddRef(); } Release(void)613 virtual ULONG STDMETHODCALLTYPE Release(void) { return DOMEvent::Release(); } 614 615 // IWebScriptObject throwException(BSTR exceptionMessage,BOOL * result)616 virtual HRESULT STDMETHODCALLTYPE throwException( 617 /* [in] */ BSTR exceptionMessage, 618 /* [retval][out] */ BOOL* result) { return DOMObject::throwException(exceptionMessage, result); } 619 callWebScriptMethod(BSTR name,const VARIANT args[],int cArgs,VARIANT * result)620 virtual HRESULT STDMETHODCALLTYPE callWebScriptMethod( 621 /* [in] */ BSTR name, 622 /* [size_is][in] */ const VARIANT args[ ], 623 /* [in] */ int cArgs, 624 /* [retval][out] */ VARIANT* result) { return DOMObject::callWebScriptMethod(name, args, cArgs, result); } 625 evaluateWebScript(BSTR script,VARIANT * result)626 virtual HRESULT STDMETHODCALLTYPE evaluateWebScript( 627 /* [in] */ BSTR script, 628 /* [retval][out] */ VARIANT* result) { return DOMObject::evaluateWebScript(script, result); } 629 removeWebScriptKey(BSTR name)630 virtual HRESULT STDMETHODCALLTYPE removeWebScriptKey( 631 /* [in] */ BSTR name) { return DOMObject::removeWebScriptKey(name); } 632 stringRepresentation(BSTR * stringRepresentation)633 virtual HRESULT STDMETHODCALLTYPE stringRepresentation( 634 /* [retval][out] */ BSTR* stringRepresentation) { return DOMObject::stringRepresentation(stringRepresentation); } 635 webScriptValueAtIndex(unsigned int index,VARIANT * result)636 virtual HRESULT STDMETHODCALLTYPE webScriptValueAtIndex( 637 /* [in] */ unsigned int index, 638 /* [retval][out] */ VARIANT* result) { return DOMObject::webScriptValueAtIndex(index, result); } 639 setWebScriptValueAtIndex(unsigned int index,VARIANT val)640 virtual HRESULT STDMETHODCALLTYPE setWebScriptValueAtIndex( 641 /* [in] */ unsigned int index, 642 /* [in] */ VARIANT val) { return DOMObject::setWebScriptValueAtIndex(index, val); } 643 setException(BSTR description)644 virtual HRESULT STDMETHODCALLTYPE setException( 645 /* [in] */ BSTR description) { return DOMObject::setException(description); } 646 647 // IDOMEvent type(BSTR * result)648 virtual HRESULT STDMETHODCALLTYPE type( 649 /* [retval][out] */ BSTR* result) { return DOMEvent::type(result); } 650 target(IDOMEventTarget ** result)651 virtual HRESULT STDMETHODCALLTYPE target( 652 /* [retval][out] */ IDOMEventTarget** result) { return DOMEvent::target(result); } 653 currentTarget(IDOMEventTarget ** result)654 virtual HRESULT STDMETHODCALLTYPE currentTarget( 655 /* [retval][out] */ IDOMEventTarget** result) { return DOMEvent::currentTarget(result); } 656 eventPhase(unsigned short * result)657 virtual HRESULT STDMETHODCALLTYPE eventPhase( 658 /* [retval][out] */ unsigned short* result) { return DOMEvent::eventPhase(result); } 659 bubbles(BOOL * result)660 virtual HRESULT STDMETHODCALLTYPE bubbles( 661 /* [retval][out] */ BOOL* result) { return DOMEvent::bubbles(result); } 662 cancelable(BOOL * result)663 virtual HRESULT STDMETHODCALLTYPE cancelable( 664 /* [retval][out] */ BOOL* result) { return DOMEvent::cancelable(result); } 665 timeStamp(DOMTimeStamp * result)666 virtual HRESULT STDMETHODCALLTYPE timeStamp( 667 /* [retval][out] */ DOMTimeStamp* result) { return DOMEvent::timeStamp(result); } 668 stopPropagation(void)669 virtual HRESULT STDMETHODCALLTYPE stopPropagation( void) { return DOMEvent::stopPropagation(); } 670 preventDefault(void)671 virtual HRESULT STDMETHODCALLTYPE preventDefault( void) { return DOMEvent::preventDefault(); } 672 initEvent(BSTR eventTypeArg,BOOL canBubbleArg,BOOL cancelableArg)673 virtual HRESULT STDMETHODCALLTYPE initEvent( 674 /* [in] */ BSTR eventTypeArg, 675 /* [in] */ BOOL canBubbleArg, 676 /* [in] */ BOOL cancelableArg) { return DOMEvent::initEvent(eventTypeArg, canBubbleArg, cancelableArg); } 677 678 // IDOMMutationEvent 679 virtual HRESULT STDMETHODCALLTYPE relatedNode( 680 /* [retval][out] */ IDOMNode** result); 681 682 virtual HRESULT STDMETHODCALLTYPE prevValue( 683 /* [retval][out] */ BSTR* result); 684 685 virtual HRESULT STDMETHODCALLTYPE newValue( 686 /* [retval][out] */ BSTR* result); 687 688 virtual HRESULT STDMETHODCALLTYPE attrName( 689 /* [retval][out] */ BSTR* result); 690 691 virtual HRESULT STDMETHODCALLTYPE attrChange( 692 /* [retval][out] */ unsigned short* result); 693 694 virtual HRESULT STDMETHODCALLTYPE initMutationEvent( 695 /* [in] */ BSTR type, 696 /* [in] */ BOOL canBubble, 697 /* [in] */ BOOL cancelable, 698 /* [in] */ IDOMNode* relatedNode, 699 /* [in] */ BSTR prevValue, 700 /* [in] */ BSTR newValue, 701 /* [in] */ BSTR attrName, 702 /* [in] */ unsigned short attrChange); 703 }; 704 705 class DOMOverflowEvent : public DOMEvent, public IDOMOverflowEvent 706 { 707 public: DOMOverflowEvent(PassRefPtr<WebCore::Event> e)708 DOMOverflowEvent(PassRefPtr<WebCore::Event> e) : DOMEvent(e) { } 709 710 // IUnknown 711 virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, void** ppvObject); AddRef(void)712 virtual ULONG STDMETHODCALLTYPE AddRef(void) { return DOMEvent::AddRef(); } Release(void)713 virtual ULONG STDMETHODCALLTYPE Release(void) { return DOMEvent::Release(); } 714 715 // IWebScriptObject throwException(BSTR exceptionMessage,BOOL * result)716 virtual HRESULT STDMETHODCALLTYPE throwException( 717 /* [in] */ BSTR exceptionMessage, 718 /* [retval][out] */ BOOL* result) { return DOMObject::throwException(exceptionMessage, result); } 719 callWebScriptMethod(BSTR name,const VARIANT args[],int cArgs,VARIANT * result)720 virtual HRESULT STDMETHODCALLTYPE callWebScriptMethod( 721 /* [in] */ BSTR name, 722 /* [size_is][in] */ const VARIANT args[ ], 723 /* [in] */ int cArgs, 724 /* [retval][out] */ VARIANT* result) { return DOMObject::callWebScriptMethod(name, args, cArgs, result); } 725 evaluateWebScript(BSTR script,VARIANT * result)726 virtual HRESULT STDMETHODCALLTYPE evaluateWebScript( 727 /* [in] */ BSTR script, 728 /* [retval][out] */ VARIANT* result) { return DOMObject::evaluateWebScript(script, result); } 729 removeWebScriptKey(BSTR name)730 virtual HRESULT STDMETHODCALLTYPE removeWebScriptKey( 731 /* [in] */ BSTR name) { return DOMObject::removeWebScriptKey(name); } 732 stringRepresentation(BSTR * stringRepresentation)733 virtual HRESULT STDMETHODCALLTYPE stringRepresentation( 734 /* [retval][out] */ BSTR* stringRepresentation) { return DOMObject::stringRepresentation(stringRepresentation); } 735 webScriptValueAtIndex(unsigned int index,VARIANT * result)736 virtual HRESULT STDMETHODCALLTYPE webScriptValueAtIndex( 737 /* [in] */ unsigned int index, 738 /* [retval][out] */ VARIANT* result) { return DOMObject::webScriptValueAtIndex(index, result); } 739 setWebScriptValueAtIndex(unsigned int index,VARIANT val)740 virtual HRESULT STDMETHODCALLTYPE setWebScriptValueAtIndex( 741 /* [in] */ unsigned int index, 742 /* [in] */ VARIANT val) { return DOMObject::setWebScriptValueAtIndex(index, val); } 743 setException(BSTR description)744 virtual HRESULT STDMETHODCALLTYPE setException( 745 /* [in] */ BSTR description) { return DOMObject::setException(description); } 746 747 // IDOMEvent type(BSTR * result)748 virtual HRESULT STDMETHODCALLTYPE type( 749 /* [retval][out] */ BSTR* result) { return DOMEvent::type(result); } 750 target(IDOMEventTarget ** result)751 virtual HRESULT STDMETHODCALLTYPE target( 752 /* [retval][out] */ IDOMEventTarget** result) { return DOMEvent::target(result); } 753 currentTarget(IDOMEventTarget ** result)754 virtual HRESULT STDMETHODCALLTYPE currentTarget( 755 /* [retval][out] */ IDOMEventTarget** result) { return DOMEvent::currentTarget(result); } 756 eventPhase(unsigned short * result)757 virtual HRESULT STDMETHODCALLTYPE eventPhase( 758 /* [retval][out] */ unsigned short* result) { return DOMEvent::eventPhase(result); } 759 bubbles(BOOL * result)760 virtual HRESULT STDMETHODCALLTYPE bubbles( 761 /* [retval][out] */ BOOL* result) { return DOMEvent::bubbles(result); } 762 cancelable(BOOL * result)763 virtual HRESULT STDMETHODCALLTYPE cancelable( 764 /* [retval][out] */ BOOL* result) { return DOMEvent::cancelable(result); } 765 timeStamp(DOMTimeStamp * result)766 virtual HRESULT STDMETHODCALLTYPE timeStamp( 767 /* [retval][out] */ DOMTimeStamp* result) { return DOMEvent::timeStamp(result); } 768 stopPropagation(void)769 virtual HRESULT STDMETHODCALLTYPE stopPropagation( void) { return DOMEvent::stopPropagation(); } 770 preventDefault(void)771 virtual HRESULT STDMETHODCALLTYPE preventDefault( void) { return DOMEvent::preventDefault(); } 772 initEvent(BSTR eventTypeArg,BOOL canBubbleArg,BOOL cancelableArg)773 virtual HRESULT STDMETHODCALLTYPE initEvent( 774 /* [in] */ BSTR eventTypeArg, 775 /* [in] */ BOOL canBubbleArg, 776 /* [in] */ BOOL cancelableArg) { return DOMEvent::initEvent(eventTypeArg, canBubbleArg, cancelableArg); } 777 778 // IDOMOverflowEvent 779 virtual HRESULT STDMETHODCALLTYPE orient( 780 /* [retval][out] */ unsigned short* result); 781 782 virtual HRESULT STDMETHODCALLTYPE horizontalOverflow( 783 /* [retval][out] */ BOOL* result); 784 785 virtual HRESULT STDMETHODCALLTYPE verticalOverflow( 786 /* [retval][out] */ BOOL* result); 787 }; 788 789 class DOMWheelEvent : public DOMUIEvent, public IDOMWheelEvent 790 { 791 public: DOMWheelEvent(PassRefPtr<WebCore::Event> e)792 DOMWheelEvent(PassRefPtr<WebCore::Event> e) : DOMUIEvent(e) { } 793 794 // IUnknown 795 virtual HRESULT STDMETHODCALLTYPE QueryInterface(REFIID riid, void** ppvObject); AddRef(void)796 virtual ULONG STDMETHODCALLTYPE AddRef(void) { return DOMUIEvent::AddRef(); } Release(void)797 virtual ULONG STDMETHODCALLTYPE Release(void) { return DOMUIEvent::Release(); } 798 799 // IWebScriptObject throwException(BSTR exceptionMessage,BOOL * result)800 virtual HRESULT STDMETHODCALLTYPE throwException( 801 /* [in] */ BSTR exceptionMessage, 802 /* [retval][out] */ BOOL* result) { return DOMObject::throwException(exceptionMessage, result); } 803 callWebScriptMethod(BSTR name,const VARIANT args[],int cArgs,VARIANT * result)804 virtual HRESULT STDMETHODCALLTYPE callWebScriptMethod( 805 /* [in] */ BSTR name, 806 /* [size_is][in] */ const VARIANT args[ ], 807 /* [in] */ int cArgs, 808 /* [retval][out] */ VARIANT* result) { return DOMObject::callWebScriptMethod(name, args, cArgs, result); } 809 evaluateWebScript(BSTR script,VARIANT * result)810 virtual HRESULT STDMETHODCALLTYPE evaluateWebScript( 811 /* [in] */ BSTR script, 812 /* [retval][out] */ VARIANT* result) { return DOMObject::evaluateWebScript(script, result); } 813 removeWebScriptKey(BSTR name)814 virtual HRESULT STDMETHODCALLTYPE removeWebScriptKey( 815 /* [in] */ BSTR name) { return DOMObject::removeWebScriptKey(name); } 816 stringRepresentation(BSTR * stringRepresentation)817 virtual HRESULT STDMETHODCALLTYPE stringRepresentation( 818 /* [retval][out] */ BSTR* stringRepresentation) { return DOMObject::stringRepresentation(stringRepresentation); } 819 webScriptValueAtIndex(unsigned int index,VARIANT * result)820 virtual HRESULT STDMETHODCALLTYPE webScriptValueAtIndex( 821 /* [in] */ unsigned int index, 822 /* [retval][out] */ VARIANT* result) { return DOMObject::webScriptValueAtIndex(index, result); } 823 setWebScriptValueAtIndex(unsigned int index,VARIANT val)824 virtual HRESULT STDMETHODCALLTYPE setWebScriptValueAtIndex( 825 /* [in] */ unsigned int index, 826 /* [in] */ VARIANT val) { return DOMObject::setWebScriptValueAtIndex(index, val); } 827 setException(BSTR description)828 virtual HRESULT STDMETHODCALLTYPE setException( 829 /* [in] */ BSTR description) { return DOMObject::setException(description); } 830 831 // IDOMEvent type(BSTR * result)832 virtual HRESULT STDMETHODCALLTYPE type( 833 /* [retval][out] */ BSTR* result) { return DOMEvent::type(result); } 834 target(IDOMEventTarget ** result)835 virtual HRESULT STDMETHODCALLTYPE target( 836 /* [retval][out] */ IDOMEventTarget** result) { return DOMEvent::target(result); } 837 currentTarget(IDOMEventTarget ** result)838 virtual HRESULT STDMETHODCALLTYPE currentTarget( 839 /* [retval][out] */ IDOMEventTarget** result) { return DOMEvent::currentTarget(result); } 840 eventPhase(unsigned short * result)841 virtual HRESULT STDMETHODCALLTYPE eventPhase( 842 /* [retval][out] */ unsigned short* result) { return DOMEvent::eventPhase(result); } 843 bubbles(BOOL * result)844 virtual HRESULT STDMETHODCALLTYPE bubbles( 845 /* [retval][out] */ BOOL* result) { return DOMEvent::bubbles(result); } 846 cancelable(BOOL * result)847 virtual HRESULT STDMETHODCALLTYPE cancelable( 848 /* [retval][out] */ BOOL* result) { return DOMEvent::cancelable(result); } 849 timeStamp(DOMTimeStamp * result)850 virtual HRESULT STDMETHODCALLTYPE timeStamp( 851 /* [retval][out] */ DOMTimeStamp* result) { return DOMEvent::timeStamp(result); } 852 stopPropagation(void)853 virtual HRESULT STDMETHODCALLTYPE stopPropagation( void) { return DOMEvent::stopPropagation(); } 854 preventDefault(void)855 virtual HRESULT STDMETHODCALLTYPE preventDefault( void) { return DOMEvent::preventDefault(); } 856 initEvent(BSTR eventTypeArg,BOOL canBubbleArg,BOOL cancelableArg)857 virtual HRESULT STDMETHODCALLTYPE initEvent( 858 /* [in] */ BSTR eventTypeArg, 859 /* [in] */ BOOL canBubbleArg, 860 /* [in] */ BOOL cancelableArg) { return DOMEvent::initEvent(eventTypeArg, canBubbleArg, cancelableArg); } 861 862 // IDOMUIEvent view(IDOMWindow ** result)863 virtual HRESULT STDMETHODCALLTYPE view( 864 /* [retval][out] */ IDOMWindow** result) { return DOMUIEvent::view(result); } 865 detail(long * result)866 virtual HRESULT STDMETHODCALLTYPE detail( 867 /* [retval][out] */ long* result) { return DOMUIEvent::detail(result); } 868 initUIEvent(BSTR type,BOOL canBubble,BOOL cancelable,IDOMWindow * view,long detail)869 virtual HRESULT STDMETHODCALLTYPE initUIEvent( 870 /* [in] */ BSTR type, 871 /* [in] */ BOOL canBubble, 872 /* [in] */ BOOL cancelable, 873 /* [in] */ IDOMWindow* view, 874 /* [in] */ long detail) { return DOMUIEvent::initUIEvent(type, canBubble, cancelable, view, detail); } 875 keyCode(long * result)876 virtual HRESULT STDMETHODCALLTYPE keyCode( 877 /* [retval][out] */ long* result) { return DOMUIEvent::keyCode(result); } 878 charCode(long * result)879 virtual HRESULT STDMETHODCALLTYPE charCode( 880 /* [retval][out] */ long* result) { return DOMUIEvent::charCode(result); } 881 layerX(long * result)882 virtual HRESULT STDMETHODCALLTYPE layerX( 883 /* [retval][out] */ long* result) { return DOMUIEvent::layerX(result); } 884 layerY(long * result)885 virtual HRESULT STDMETHODCALLTYPE layerY( 886 /* [retval][out] */ long* result) { return DOMUIEvent::layerY(result); } 887 pageX(long * result)888 virtual HRESULT STDMETHODCALLTYPE pageX( 889 /* [retval][out] */ long* result) { return DOMUIEvent::pageX(result); } 890 pageY(long * result)891 virtual HRESULT STDMETHODCALLTYPE pageY( 892 /* [retval][out] */ long* result) { return DOMUIEvent::pageY(result); } 893 which(long * result)894 virtual HRESULT STDMETHODCALLTYPE which( 895 /* [retval][out] */ long* result) { return DOMUIEvent::which(result); } 896 897 // IDOMWheelEvent 898 virtual HRESULT STDMETHODCALLTYPE screenX( 899 /* [retval][out] */ long* result); 900 901 virtual HRESULT STDMETHODCALLTYPE screenY( 902 /* [retval][out] */ long* result); 903 904 virtual HRESULT STDMETHODCALLTYPE clientX( 905 /* [retval][out] */ long* result); 906 907 virtual HRESULT STDMETHODCALLTYPE clientY( 908 /* [retval][out] */ long* result); 909 910 virtual HRESULT STDMETHODCALLTYPE ctrlKey( 911 /* [retval][out] */ BOOL* result); 912 913 virtual HRESULT STDMETHODCALLTYPE shiftKey( 914 /* [retval][out] */ BOOL* result); 915 916 virtual HRESULT STDMETHODCALLTYPE altKey( 917 /* [retval][out] */ BOOL* result); 918 919 virtual HRESULT STDMETHODCALLTYPE metaKey( 920 /* [retval][out] */ BOOL* result); 921 922 virtual HRESULT STDMETHODCALLTYPE wheelDelta( 923 /* [retval][out] */ long* result); 924 925 virtual HRESULT STDMETHODCALLTYPE wheelDeltaX( 926 /* [retval][out] */ long* result); 927 928 virtual HRESULT STDMETHODCALLTYPE wheelDeltaY( 929 /* [retval][out] */ long* result); 930 931 virtual HRESULT STDMETHODCALLTYPE offsetX( 932 /* [retval][out] */ long* result); 933 934 virtual HRESULT STDMETHODCALLTYPE offsetY( 935 /* [retval][out] */ long* result); 936 937 virtual HRESULT STDMETHODCALLTYPE x( 938 /* [retval][out] */ long* result); 939 940 virtual HRESULT STDMETHODCALLTYPE y( 941 /* [retval][out] */ long* result); 942 943 virtual HRESULT STDMETHODCALLTYPE isHorizontal( 944 /* [retval][out] */ BOOL* result); 945 946 virtual HRESULT STDMETHODCALLTYPE initWheelEvent( 947 /* [in] */ long wheelDeltaX, 948 /* [in] */ long wheelDeltaY, 949 /* [in] */ IDOMWindow* view, 950 /* [in] */ long screenX, 951 /* [in] */ long screenY, 952 /* [in] */ long clientX, 953 /* [in] */ long clientY, 954 /* [in] */ BOOL ctrlKey, 955 /* [in] */ BOOL altKey, 956 /* [in] */ BOOL shiftKey, 957 /* [in] */ BOOL metaKey); 958 }; 959 960 #endif 961