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 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
127 private: | 127 private: |
128 WorkerContext* m_context; | 128 WorkerContext* m_context; |
129 }; | 129 }; |
130 friend class Observer; | 130 friend class Observer; |
131 void registerObserver(Observer*); | 131 void registerObserver(Observer*); |
132 void unregisterObserver(Observer*); | 132 void unregisterObserver(Observer*); |
133 void notifyObserversOfStop(); | 133 void notifyObserversOfStop(); |
134 | 134 |
135 virtual const SecurityOrigin* topOrigin() const OVERRIDE { return m_topO
rigin.get(); } | 135 virtual const SecurityOrigin* topOrigin() const OVERRIDE { return m_topO
rigin.get(); } |
136 | 136 |
137 virtual void visitWith(Visitor* visitor) const OVERRIDE | 137 virtual void adjustAndMark(Visitor* visitor) const OVERRIDE |
138 { | 138 { |
139 visitor->visit(this); | 139 visitor->mark(this); |
140 } | 140 } |
141 | 141 |
142 virtual void trace(Visitor*) { } | 142 virtual void trace(Visitor*) { } |
143 virtual bool isAlive(Visitor* visitor) { return visitor->isMarked(this);
} | 143 virtual bool isAlive(Visitor* visitor) { return visitor->isMarked(this);
} |
144 | 144 |
145 protected: | 145 protected: |
146 WorkerContext(const KURL&, const String& userAgent, PassOwnPtr<GroupSett
ings>, WorkerThread*, PassRefPtr<SecurityOrigin> topOrigin); | 146 WorkerContext(const KURL&, const String& userAgent, PassOwnPtr<GroupSett
ings>, WorkerThread*, PassRefPtr<SecurityOrigin> topOrigin); |
147 void applyContentSecurityPolicyFromString(const String& contentSecurityP
olicy, ContentSecurityPolicy::HeaderType); | 147 void applyContentSecurityPolicyFromString(const String& contentSecurityP
olicy, ContentSecurityPolicy::HeaderType); |
148 | 148 |
149 virtual void logExceptionToConsole(const String& errorMessage, const Str
ing& sourceURL, int lineNumber, PassRefPtr<ScriptCallStack>) OVERRIDE; | 149 virtual void logExceptionToConsole(const String& errorMessage, const Str
ing& sourceURL, int lineNumber, PassRefPtr<ScriptCallStack>) OVERRIDE; |
(...skipping 29 matching lines...) Expand all Loading... |
179 HashSet<Observer*> m_workerObservers; | 179 HashSet<Observer*> m_workerObservers; |
180 | 180 |
181 OwnPtr<WorkerEventQueue> m_eventQueue; | 181 OwnPtr<WorkerEventQueue> m_eventQueue; |
182 | 182 |
183 RefPtr<SecurityOrigin> m_topOrigin; | 183 RefPtr<SecurityOrigin> m_topOrigin; |
184 }; | 184 }; |
185 | 185 |
186 } // namespace WebCore | 186 } // namespace WebCore |
187 | 187 |
188 #endif // WorkerContext_h | 188 #endif // WorkerContext_h |
OLD | NEW |