| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008, 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2008, 2009 Apple 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 | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 124 double timeOrigin() const { return m_timeOrigin; } | 124 double timeOrigin() const { return m_timeOrigin; } |
| 125 | 125 |
| 126 WorkerClients* clients() { return m_workerClients.get(); } | 126 WorkerClients* clients() { return m_workerClients.get(); } |
| 127 | 127 |
| 128 using SecurityContext::securityOrigin; | 128 using SecurityContext::securityOrigin; |
| 129 using SecurityContext::contentSecurityPolicy; | 129 using SecurityContext::contentSecurityPolicy; |
| 130 | 130 |
| 131 virtual void trace(Visitor*); | 131 virtual void trace(Visitor*); |
| 132 | 132 |
| 133 protected: | 133 protected: |
| 134 WorkerGlobalScope(const KURL&, const String& userAgent, WorkerThread*, d
ouble timeOrigin, PassOwnPtr<WorkerClients>); | 134 WorkerGlobalScope(const KURL&, const String& userAgent, WorkerThread*, d
ouble timeOrigin, PassOwnPtrWillBeRawPtr<WorkerClients>); |
| 135 void applyContentSecurityPolicyFromString(const String& contentSecurityP
olicy, ContentSecurityPolicyHeaderType); | 135 void applyContentSecurityPolicyFromString(const String& contentSecurityP
olicy, ContentSecurityPolicyHeaderType); |
| 136 | 136 |
| 137 virtual void logExceptionToConsole(const String& errorMessage, const Str
ing& sourceURL, int lineNumber, int columnNumber, PassRefPtr<ScriptCallStack>) O
VERRIDE; | 137 virtual void logExceptionToConsole(const String& errorMessage, const Str
ing& sourceURL, int lineNumber, int columnNumber, PassRefPtr<ScriptCallStack>) O
VERRIDE; |
| 138 void addMessageToWorkerConsole(MessageSource, MessageLevel, const String
& message, const String& sourceURL, unsigned lineNumber, PassRefPtr<ScriptCallSt
ack>, ScriptState*); | 138 void addMessageToWorkerConsole(MessageSource, MessageLevel, const String
& message, const String& sourceURL, unsigned lineNumber, PassRefPtr<ScriptCallSt
ack>, ScriptState*); |
| 139 | 139 |
| 140 private: | 140 private: |
| 141 virtual void refExecutionContext() OVERRIDE FINAL { ref(); } | 141 virtual void refExecutionContext() OVERRIDE FINAL { ref(); } |
| 142 virtual void derefExecutionContext() OVERRIDE FINAL { deref(); } | 142 virtual void derefExecutionContext() OVERRIDE FINAL { deref(); } |
| 143 | 143 |
| 144 virtual const KURL& virtualURL() const OVERRIDE FINAL; | 144 virtual const KURL& virtualURL() const OVERRIDE FINAL; |
| (...skipping 13 matching lines...) Expand all Loading... |
| 158 mutable RefPtrWillBeMember<WorkerNavigator> m_navigator; | 158 mutable RefPtrWillBeMember<WorkerNavigator> m_navigator; |
| 159 | 159 |
| 160 OwnPtr<WorkerScriptController> m_script; | 160 OwnPtr<WorkerScriptController> m_script; |
| 161 WorkerThread* m_thread; | 161 WorkerThread* m_thread; |
| 162 | 162 |
| 163 OwnPtr<WorkerInspectorController> m_workerInspectorController; | 163 OwnPtr<WorkerInspectorController> m_workerInspectorController; |
| 164 bool m_closing; | 164 bool m_closing; |
| 165 | 165 |
| 166 OwnPtr<WorkerEventQueue> m_eventQueue; | 166 OwnPtr<WorkerEventQueue> m_eventQueue; |
| 167 | 167 |
| 168 OwnPtr<WorkerClients> m_workerClients; | 168 OwnPtrWillBeMember<WorkerClients> m_workerClients; |
| 169 | 169 |
| 170 double m_timeOrigin; | 170 double m_timeOrigin; |
| 171 }; | 171 }; |
| 172 | 172 |
| 173 DEFINE_TYPE_CASTS(WorkerGlobalScope, ExecutionContext, context, context->isWorke
rGlobalScope(), context.isWorkerGlobalScope()); | 173 DEFINE_TYPE_CASTS(WorkerGlobalScope, ExecutionContext, context, context->isWorke
rGlobalScope(), context.isWorkerGlobalScope()); |
| 174 | 174 |
| 175 } // namespace WebCore | 175 } // namespace WebCore |
| 176 | 176 |
| 177 #endif // WorkerGlobalScope_h | 177 #endif // WorkerGlobalScope_h |
| OLD | NEW |