| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008, 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2008, 2009 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 26 matching lines...) Expand all Loading... |
| 37 #include "V8CustomBinding.h" | 37 #include "V8CustomBinding.h" |
| 38 #include "V8HTMLDocument.h" | 38 #include "V8HTMLDocument.h" |
| 39 #include "V8ObjectEventListener.h" | 39 #include "V8ObjectEventListener.h" |
| 40 #include "V8Proxy.h" | 40 #include "V8Proxy.h" |
| 41 #include "V8Utilities.h" | 41 #include "V8Utilities.h" |
| 42 #include "WorkerContext.h" | 42 #include "WorkerContext.h" |
| 43 #include "WorkerContextExecutionProxy.h" | 43 #include "WorkerContextExecutionProxy.h" |
| 44 | 44 |
| 45 namespace WebCore { | 45 namespace WebCore { |
| 46 | 46 |
| 47 PassRefPtr<EventListener> getEventListener(XMLHttpRequest* xmlHttpRequest, v8::L
ocal<v8::Value> value, bool findOnly) | 47 static PassRefPtr<EventListener> getEventListener(XMLHttpRequest* xmlHttpRequest
, v8::Local<v8::Value> value, bool findOnly) |
| 48 { | 48 { |
| 49 #if ENABLE(WORKERS) | 49 #if ENABLE(WORKERS) |
| 50 WorkerContextExecutionProxy* workerContextProxy = WorkerContextExecutionProx
y::retrieve(); | 50 WorkerContextExecutionProxy* workerContextProxy = WorkerContextExecutionProx
y::retrieve(); |
| 51 if (workerContextProxy) | 51 if (workerContextProxy) |
| 52 return workerContextProxy->findOrCreateObjectEventListener(value, false,
findOnly); | 52 return workerContextProxy->findOrCreateObjectEventListener(value, false,
findOnly); |
| 53 #endif | 53 #endif |
| 54 | 54 |
| 55 V8Proxy* proxy = V8Proxy::retrieve(xmlHttpRequest->scriptExecutionContext())
; | 55 V8Proxy* proxy = V8Proxy::retrieve(xmlHttpRequest->scriptExecutionContext())
; |
| 56 if (proxy) { | 56 if (proxy) { |
| 57 V8EventListenerList* list = proxy->objectListeners(); | 57 V8EventListenerList* list = proxy->objectListeners(); |
| (...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 437 return v8::Undefined(); | 437 return v8::Undefined(); |
| 438 } | 438 } |
| 439 | 439 |
| 440 CALLBACK_FUNC_DECL(XMLHttpRequestDispatchEvent) | 440 CALLBACK_FUNC_DECL(XMLHttpRequestDispatchEvent) |
| 441 { | 441 { |
| 442 INC_STATS("DOM.XMLHttpRequest.dispatchEvent()"); | 442 INC_STATS("DOM.XMLHttpRequest.dispatchEvent()"); |
| 443 return v8::Undefined(); | 443 return v8::Undefined(); |
| 444 } | 444 } |
| 445 | 445 |
| 446 } // namespace WebCore | 446 } // namespace WebCore |
| OLD | NEW |