X-Git-Url: http://git.webkit.org/?p=WebKit-https.git;a=blobdiff_plain;f=WebCore%2Fbindings%2Fjs%2FJSLazyEventListener.cpp;h=3c80efeac05e0c4df26f3948369ae7e27fb8ed9e;hp=1dd84cd62ec2f07ea2780a85d0e97f2cd50cc050;hb=20d1868426b9b0fe253f232112ad9b6c3413185b;hpb=ecc8b3842e3446417abdc31ee8f2c444fa7e8d9e diff --git a/WebCore/bindings/js/JSLazyEventListener.cpp b/WebCore/bindings/js/JSLazyEventListener.cpp index 1dd84cd..3c80efe 100644 --- a/WebCore/bindings/js/JSLazyEventListener.cpp +++ b/WebCore/bindings/js/JSLazyEventListener.cpp @@ -1,6 +1,6 @@ /* * Copyright (C) 2001 Peter Kelly (pmk@post.com) - * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Apple Inc. All Rights Reserved. + * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All Rights Reserved. * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -49,7 +49,7 @@ JSLazyEventListener::JSLazyEventListener(LazyEventListenerType type, const Strin m_lineNumber = 1; } -JSObject* JSLazyEventListener::listenerObj() const +JSObject* JSLazyEventListener::function() const { parseCode(); return m_listener; @@ -74,8 +74,8 @@ void JSLazyEventListener::parseCode() const if (m_parsed) return; - if (globalObject()->scriptExecutionContext()->isDocument()) { - JSDOMWindow* window = static_cast(globalObject()); + if (m_globalObject->scriptExecutionContext()->isDocument()) { + JSDOMWindow* window = static_cast(m_globalObject.get()); Frame* frame = window->impl()->frame(); if (!frame) return; @@ -87,10 +87,10 @@ void JSLazyEventListener::parseCode() const m_parsed = true; - ExecState* exec = globalObject()->globalExec(); + ExecState* exec = m_globalObject->globalExec(); ArgList args; - UString sourceURL(globalObject()->scriptExecutionContext()->url().string()); + UString sourceURL(m_globalObject->scriptExecutionContext()->url().string()); args.append(eventParameterName(m_type, exec)); args.append(jsString(exec, m_code)); @@ -123,7 +123,7 @@ void JSLazyEventListener::parseCode() const if (m_listener) { ASSERT(isInline()); - JSDOMWindow::ProtectedListenersMap& listeners = globalObject()->jsProtectedInlineEventListeners(); + JSDOMWindow::ProtectedListenersMap& listeners = m_globalObject->jsProtectedInlineEventListeners(); listeners.set(m_listener, const_cast(this)); } }