PageRenderTime 117ms CodeModel.GetById 40ms app.highlight 10ms RepoModel.GetById 61ms app.codeStats 0ms

/gecko_api/include/nsIDOMEventListener.h

http://firefox-mac-pdf.googlecode.com/
C++ Header | 109 lines | 48 code | 26 blank | 35 comment | 0 complexity | f87092680eb7a376b1ad6d798ebb28de MD5 | raw file
  1/*
  2 * DO NOT EDIT.  THIS FILE IS GENERATED FROM /builds/tinderbox/XR-Trunk/Darwin_8.8.4_Depend/mozilla/dom/public/idl/events/nsIDOMEventListener.idl
  3 */
  4
  5#ifndef __gen_nsIDOMEventListener_h__
  6#define __gen_nsIDOMEventListener_h__
  7
  8
  9#ifndef __gen_domstubs_h__
 10#include "domstubs.h"
 11#endif
 12
 13/* For IDL files that don't want to include root IDL files. */
 14#ifndef NS_NO_VTABLE
 15#define NS_NO_VTABLE
 16#endif
 17
 18/* starting interface:    nsIDOMEventListener */
 19#define NS_IDOMEVENTLISTENER_IID_STR "df31c120-ded6-11d1-bd85-00805f8ae3f4"
 20
 21#define NS_IDOMEVENTLISTENER_IID \
 22  {0xdf31c120, 0xded6, 0x11d1, \
 23    { 0xbd, 0x85, 0x00, 0x80, 0x5f, 0x8a, 0xe3, 0xf4 }}
 24
 25class NS_NO_VTABLE NS_SCRIPTABLE nsIDOMEventListener : public nsISupports {
 26 public: 
 27
 28  NS_DECLARE_STATIC_IID_ACCESSOR(NS_IDOMEVENTLISTENER_IID)
 29
 30  /**
 31 * The nsIDOMEventListener interface is a callback interface for
 32 * listening to events in the Document Object Model.
 33 *
 34 * For more information on this interface please see 
 35 * http://www.w3.org/TR/DOM-Level-2-Events/
 36 *
 37 * @status FROZEN
 38 */
 39/**
 40   * This method is called whenever an event occurs of the type for which 
 41   * the EventListener interface was registered.
 42   *
 43   * @param   evt The Event contains contextual information about the 
 44   *              event. It also contains the stopPropagation and 
 45   *              preventDefault methods which are used in determining the 
 46   *              event's flow and default action.
 47   */
 48  /* void handleEvent (in nsIDOMEvent event); */
 49  NS_SCRIPTABLE NS_IMETHOD HandleEvent(nsIDOMEvent *event) = 0;
 50
 51};
 52
 53  NS_DEFINE_STATIC_IID_ACCESSOR(nsIDOMEventListener, NS_IDOMEVENTLISTENER_IID)
 54
 55/* Use this macro when declaring classes that implement this interface. */
 56#define NS_DECL_NSIDOMEVENTLISTENER \
 57  NS_SCRIPTABLE NS_IMETHOD HandleEvent(nsIDOMEvent *event); 
 58
 59/* Use this macro to declare functions that forward the behavior of this interface to another object. */
 60#define NS_FORWARD_NSIDOMEVENTLISTENER(_to) \
 61  NS_SCRIPTABLE NS_IMETHOD HandleEvent(nsIDOMEvent *event) { return _to HandleEvent(event); } 
 62
 63/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
 64#define NS_FORWARD_SAFE_NSIDOMEVENTLISTENER(_to) \
 65  NS_SCRIPTABLE NS_IMETHOD HandleEvent(nsIDOMEvent *event) { return !_to ? NS_ERROR_NULL_POINTER : _to->HandleEvent(event); } 
 66
 67#if 0
 68/* Use the code below as a template for the implementation class for this interface. */
 69
 70/* Header file */
 71class nsDOMEventListener : public nsIDOMEventListener
 72{
 73public:
 74  NS_DECL_ISUPPORTS
 75  NS_DECL_NSIDOMEVENTLISTENER
 76
 77  nsDOMEventListener();
 78
 79private:
 80  ~nsDOMEventListener();
 81
 82protected:
 83  /* additional members */
 84};
 85
 86/* Implementation file */
 87NS_IMPL_ISUPPORTS1(nsDOMEventListener, nsIDOMEventListener)
 88
 89nsDOMEventListener::nsDOMEventListener()
 90{
 91  /* member initializers and constructor code */
 92}
 93
 94nsDOMEventListener::~nsDOMEventListener()
 95{
 96  /* destructor code */
 97}
 98
 99/* void handleEvent (in nsIDOMEvent event); */
100NS_IMETHODIMP nsDOMEventListener::HandleEvent(nsIDOMEvent *event)
101{
102    return NS_ERROR_NOT_IMPLEMENTED;
103}
104
105/* End of implementation class template. */
106#endif
107
108
109#endif /* __gen_nsIDOMEventListener_h__ */