OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2011 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 23 matching lines...) Expand all Loading... |
34 | 34 |
35 namespace WebCore { | 35 namespace WebCore { |
36 | 36 |
37 class Document; | 37 class Document; |
38 class TextTrackLoader; | 38 class TextTrackLoader; |
39 | 39 |
40 class TextTrackLoaderClient { | 40 class TextTrackLoaderClient { |
41 public: | 41 public: |
42 virtual ~TextTrackLoaderClient() { } | 42 virtual ~TextTrackLoaderClient() { } |
43 | 43 |
44 virtual bool shouldLoadCues(TextTrackLoader*) = 0; | |
45 virtual void newCuesAvailable(TextTrackLoader*) = 0; | 44 virtual void newCuesAvailable(TextTrackLoader*) = 0; |
46 virtual void cueLoadingStarted(TextTrackLoader*) = 0; | |
47 virtual void cueLoadingCompleted(TextTrackLoader*, bool loadingFailed) = 0; | 45 virtual void cueLoadingCompleted(TextTrackLoader*, bool loadingFailed) = 0; |
48 virtual void newRegionsAvailable(TextTrackLoader*) = 0; | 46 virtual void newRegionsAvailable(TextTrackLoader*) = 0; |
49 }; | 47 }; |
50 | 48 |
51 class TextTrackLoader : public RawResourceClient, private WebVTTParserClient { | 49 class TextTrackLoader : public RawResourceClient, private WebVTTParserClient { |
52 WTF_MAKE_NONCOPYABLE(TextTrackLoader); | 50 WTF_MAKE_NONCOPYABLE(TextTrackLoader); |
53 WTF_MAKE_FAST_ALLOCATED; | 51 WTF_MAKE_FAST_ALLOCATED; |
54 public: | 52 public: |
55 static PassOwnPtr<TextTrackLoader> create(TextTrackLoaderClient& client, Doc
ument& document) | 53 static PassOwnPtr<TextTrackLoader> create(TextTrackLoaderClient& client, Doc
ument& document) |
56 { | 54 { |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
89 Document& m_document; | 87 Document& m_document; |
90 Timer<TextTrackLoader> m_cueLoadTimer; | 88 Timer<TextTrackLoader> m_cueLoadTimer; |
91 String m_crossOriginMode; | 89 String m_crossOriginMode; |
92 State m_state; | 90 State m_state; |
93 bool m_newCuesAvailable; | 91 bool m_newCuesAvailable; |
94 }; | 92 }; |
95 | 93 |
96 } // namespace WebCore | 94 } // namespace WebCore |
97 | 95 |
98 #endif | 96 #endif |
OLD | NEW |