JSLazyEventListener.h [plain text]
#ifndef JSLazyEventListener_h
#define JSLazyEventListener_h
#include "JSEventListener.h"
#include "PlatformString.h"
#include <wtf/text/TextPosition.h>
namespace WebCore {
class Node;
class JSLazyEventListener : public JSEventListener {
public:
static PassRefPtr<JSLazyEventListener> create(const String& functionName, const String& eventParameterName, const String& code, Node* node, const String& sourceURL, const TextPosition& position, JSC::JSObject* wrapper, DOMWrapperWorld* isolatedWorld)
{
return adoptRef(new JSLazyEventListener(functionName, eventParameterName, code, node, sourceURL, position, wrapper, isolatedWorld));
}
virtual ~JSLazyEventListener();
private:
JSLazyEventListener(const String& functionName, const String& eventParameterName, const String& code, Node*, const String& sourceURL, const TextPosition&, JSC::JSObject* wrapper, DOMWrapperWorld* isolatedWorld);
virtual JSC::JSObject* initializeJSFunction(ScriptExecutionContext*) const;
virtual bool wasCreatedFromMarkup() const { return true; }
mutable String m_functionName;
mutable String m_eventParameterName;
mutable String m_code;
mutable String m_sourceURL;
TextPosition m_position;
Node* m_originalNode;
};
}
#endif // JSEventListener_h