JSEventTargetNode.h [plain text]
#ifndef JSEventTargetNode_h
#define JSEventTargetNode_h
#include "JSNode.h"
namespace WebCore {
class EventTargetNode;
class Node;
class JSEventTargetNode : public JSNode {
public:
JSEventTargetNode(KJS::ExecState*, Node* n);
void setListener(KJS::ExecState*, const AtomicString& eventType, KJS::JSValue* func) const;
KJS::JSValue* getListener(const AtomicString& eventType) const;
virtual void pushEventHandlerScope(KJS::ExecState*, KJS::ScopeChain&) const;
bool getOwnPropertySlot(KJS::ExecState*, const KJS::Identifier&, KJS::PropertySlot&);
KJS::JSValue* getValueProperty(KJS::ExecState*, int token) const;
virtual void put(KJS::ExecState*, const KJS::Identifier&, KJS::JSValue* value, int attr);
void putValueProperty(KJS::ExecState*, int token, KJS::JSValue* value, int attr);
enum {
AddEventListener, RemoveEventListener, DispatchEvent,
OnAbort, OnBlur, OnChange, OnClick, OnContextMenu, OnDblClick, OnError,
OnDragEnter, OnDragOver, OnDragLeave, OnDrop, OnDragStart, OnDrag, OnDragEnd,
OnBeforeCut, OnCut, OnBeforeCopy, OnCopy, OnBeforePaste, OnPaste, OnSelectStart,
OnFocus, OnInput, OnKeyDown, OnKeyPress, OnKeyUp, OnLoad, OnMouseDown,
OnMouseMove, OnMouseOut, OnMouseOver, OnMouseUp, OnMouseWheel, OnReset,
OnResize, OnScroll, OnSearch, OnSelect, OnSubmit, OnUnload
};
};
EventTargetNode* toEventTargetNode(KJS::JSValue*);
KJS_DEFINE_PROTOTYPE_WITH_PROTOTYPE(JSEventTargetNodePrototype, JSNodePrototype)
}
#endif // JSEventTargetNode_h