OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010 Google, Inc. All Rights Reserved. | 2 * Copyright (C) 2010 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 | 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 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
128 if (m_streamer) | 128 if (m_streamer) |
129 m_streamer->notifyFinished(resource); | 129 m_streamer->notifyFinished(resource); |
130 } | 130 } |
131 | 131 |
132 void PendingScript::notifyAppendData(ScriptResource* resource) | 132 void PendingScript::notifyAppendData(ScriptResource* resource) |
133 { | 133 { |
134 if (m_streamer) | 134 if (m_streamer) |
135 m_streamer->notifyAppendData(resource); | 135 m_streamer->notifyAppendData(resource); |
136 } | 136 } |
137 | 137 |
138 void PendingScript::trace(Visitor* visitor) | 138 DEFINE_TRACE(PendingScript) |
139 { | 139 { |
140 visitor->trace(m_element); | 140 visitor->trace(m_element); |
141 visitor->trace(m_streamer); | 141 visitor->trace(m_streamer); |
142 } | 142 } |
143 | 143 |
144 ScriptSourceCode PendingScript::getSource(const KURL& documentURL, bool& errorOc
curred) const | 144 ScriptSourceCode PendingScript::getSource(const KURL& documentURL, bool& errorOc
curred) const |
145 { | 145 { |
146 if (resource()) { | 146 if (resource()) { |
147 errorOccurred = resource()->errorOccurred(); | 147 errorOccurred = resource()->errorOccurred(); |
148 ASSERT(resource()->isLoaded()); | 148 ASSERT(resource()->isLoaded()); |
(...skipping 15 matching lines...) Expand all Loading... |
164 bool PendingScript::isReady() const | 164 bool PendingScript::isReady() const |
165 { | 165 { |
166 if (resource() && !resource()->isLoaded()) | 166 if (resource() && !resource()->isLoaded()) |
167 return false; | 167 return false; |
168 if (m_streamer && !m_streamer->isFinished()) | 168 if (m_streamer && !m_streamer->isFinished()) |
169 return false; | 169 return false; |
170 return true; | 170 return true; |
171 } | 171 } |
172 | 172 |
173 } | 173 } |
OLD | NEW |