~ubuntu-branches/ubuntu/lucid/webkit/lucid-updates

« back to all changes in this revision

Viewing changes to WebCore/bindings/js/JSEventListener.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Gustavo Noronha Silva
  • Date: 2010-01-06 21:25:06 UTC
  • mfrom: (1.2.6 upstream) (4.3.7 sid)
  • Revision ID: james.westby@ubuntu.com-20100106212506-gd0czn4zrwf1j19l
* New upstream release
- adds basic Content-Encoding support, thanks to soup
  (Closes: #529271)
- fixes over-advertising content types as supported by
  the media player (Closes: #559420)
* debian/control:
- updated libsoup build requirement (>= 2.28.2)
* debian/libwebkit-1.0-2.symbols:
- updated with new symbols
* debian/copyright:
- updated information since 1.1.17
* Imported patch from https://bugs.webkit.org/show_bug.cgi?id=30623
- I am shipping this patch because I believe it is correct, it is the
  way to go, it fixes a race, and it needs testing.

Show diffs side-by-side

added added

removed removed

Lines of Context:
86
86
    }
87
87
 
88
88
    ExecState* exec = globalObject->globalExec();
 
89
    JSValue handleEventFunction = jsFunction->get(exec, Identifier(exec, "handleEvent"));
89
90
 
90
 
    JSValue handleEventFunction;
91
 
    {
92
 
        // Switch worlds, just in case handleEvent is a getter and causes JS execution!
93
 
        EnterDOMWrapperWorld worldEntry(exec, m_isolatedWorld.get());
94
 
        handleEventFunction = jsFunction->get(exec, Identifier(exec, "handleEvent"));
95
 
    }
96
91
    CallData callData;
97
92
    CallType callType = handleEventFunction.getCallData(callData);
98
93
    if (callType == CallTypeNone) {
114
109
 
115
110
        globalData->timeoutChecker.start();
116
111
        JSValue retval = handleEventFunction
117
 
            ? callInWorld(exec, handleEventFunction, callType, callData, jsFunction, args, m_isolatedWorld.get())
118
 
            : callInWorld(exec, jsFunction, callType, callData, toJS(exec, globalObject, event->currentTarget()), args, m_isolatedWorld.get());
 
112
            ? JSC::call(exec, handleEventFunction, callType, callData, jsFunction, args)
 
113
            : JSC::call(exec, jsFunction, callType, callData, toJS(exec, globalObject, event->currentTarget()), args);
119
114
        globalData->timeoutChecker.stop();
120
115
 
121
116
        globalObject->setCurrentEvent(savedEvent);
166
161
    JSValue thisValue = globalObject->toThisObject(exec);
167
162
 
168
163
    globalData->timeoutChecker.start();
169
 
    JSValue returnValue = callInWorld(exec, jsFunction, callType, callData, thisValue, args, m_isolatedWorld.get());
 
164
    JSValue returnValue = JSC::call(exec, jsFunction, callType, callData, thisValue, args);
170
165
    globalData->timeoutChecker.stop();
171
166
 
172
167
    // If an error occurs while handling the script error, it should be bubbled up.