| 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 27 matching lines...) Expand all Loading... |
| 38 namespace blink { | 38 namespace blink { |
| 39 | 39 |
| 40 class ScriptSourceCode; | 40 class ScriptSourceCode; |
| 41 class ScriptStreamer; | 41 class ScriptStreamer; |
| 42 | 42 |
| 43 // A container for an external script which may be loaded and executed. | 43 // A container for an external script which may be loaded and executed. |
| 44 // | 44 // |
| 45 // A ResourcePtr alone does not prevent the underlying Resource | 45 // A ResourcePtr alone does not prevent the underlying Resource |
| 46 // from purging its data buffer. This class holds a dummy client open for its | 46 // from purging its data buffer. This class holds a dummy client open for its |
| 47 // lifetime in order to guarantee that the data buffer will not be purged. | 47 // lifetime in order to guarantee that the data buffer will not be purged. |
| 48 class PendingScript FINAL : public ResourceOwner<ScriptResource> { | 48 class PendingScript final : public ResourceOwner<ScriptResource> { |
| 49 ALLOW_ONLY_INLINE_ALLOCATION(); | 49 ALLOW_ONLY_INLINE_ALLOCATION(); |
| 50 public: | 50 public: |
| 51 enum Type { | 51 enum Type { |
| 52 ParsingBlocking, | 52 ParsingBlocking, |
| 53 Deferred, | 53 Deferred, |
| 54 Async | 54 Async |
| 55 }; | 55 }; |
| 56 | 56 |
| 57 PendingScript() | 57 PendingScript() |
| 58 : m_watchingForLoad(false) | 58 : m_watchingForLoad(false) |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 124 bool m_watchingForLoad; | 124 bool m_watchingForLoad; |
| 125 RefPtrWillBeMember<Element> m_element; | 125 RefPtrWillBeMember<Element> m_element; |
| 126 TextPosition m_startingPosition; // Only used for inline script tags. | 126 TextPosition m_startingPosition; // Only used for inline script tags. |
| 127 | 127 |
| 128 RefPtr<ScriptStreamer> m_streamer; | 128 RefPtr<ScriptStreamer> m_streamer; |
| 129 }; | 129 }; |
| 130 | 130 |
| 131 } | 131 } |
| 132 | 132 |
| 133 #endif | 133 #endif |
| OLD | NEW |