| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 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 are met: | 5 * modification, are permitted provided that the following conditions are met: |
| 6 * | 6 * |
| 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 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 63 typedef HeapSupplement<Document> SupplementType; | 63 typedef HeapSupplement<Document> SupplementType; |
| 64 #else | 64 #else |
| 65 class FontFaceSet FINAL : public RefCountedSupplement<Document, FontFaceSet>, pu
blic ActiveDOMObject, public EventTargetWithInlineData { | 65 class FontFaceSet FINAL : public RefCountedSupplement<Document, FontFaceSet>, pu
blic ActiveDOMObject, public EventTargetWithInlineData { |
| 66 DEFINE_EVENT_TARGET_REFCOUNTING(RefCounted<FontFaceSet>); | 66 DEFINE_EVENT_TARGET_REFCOUNTING(RefCounted<FontFaceSet>); |
| 67 typedef RefCountedSupplement<Document, FontFaceSet> SupplementType; | 67 typedef RefCountedSupplement<Document, FontFaceSet> SupplementType; |
| 68 #endif | 68 #endif |
| 69 DEFINE_WRAPPERTYPEINFO(); | 69 DEFINE_WRAPPERTYPEINFO(); |
| 70 public: | 70 public: |
| 71 virtual ~FontFaceSet(); | 71 virtual ~FontFaceSet(); |
| 72 | 72 |
| 73 DEFINE_ATTRIBUTE_EVENT_LISTENER(loading); | |
| 74 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadingdone); | |
| 75 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadingerror); | |
| 76 | |
| 77 bool check(const String& font, const String& text, ExceptionState&); | 73 bool check(const String& font, const String& text, ExceptionState&); |
| 78 ScriptPromise load(ScriptState*, const String& font, const String& text); | 74 ScriptPromise load(ScriptState*, const String& font, const String& text); |
| 79 ScriptPromise ready(ScriptState*); | 75 ScriptPromise ready(ScriptState*); |
| 80 | 76 |
| 81 void add(FontFace*, ExceptionState&); | 77 void add(FontFace*, ExceptionState&); |
| 82 void clear(); | 78 void clear(); |
| 83 bool remove(FontFace*, ExceptionState&); | 79 bool remove(FontFace*, ExceptionState&); |
| 84 void forEach(PassOwnPtrWillBeRawPtr<FontFaceSetForEachCallback>, const Scrip
tValue& thisArg) const; | 80 void forEach(PassOwnPtrWillBeRawPtr<FontFaceSetForEachCallback>, const Scrip
tValue& thisArg) const; |
| 85 void forEach(PassOwnPtrWillBeRawPtr<FontFaceSetForEachCallback>) const; | 81 void forEach(PassOwnPtrWillBeRawPtr<FontFaceSetForEachCallback>) const; |
| 86 bool has(FontFace*, ExceptionState&) const; | 82 bool has(FontFace*, ExceptionState&) const; |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 156 WillBeHeapListHashSet<RefPtrWillBeMember<FontFace> > m_nonCSSConnectedFaces; | 152 WillBeHeapListHashSet<RefPtrWillBeMember<FontFace> > m_nonCSSConnectedFaces; |
| 157 | 153 |
| 158 AsyncMethodRunner<FontFaceSet> m_asyncRunner; | 154 AsyncMethodRunner<FontFaceSet> m_asyncRunner; |
| 159 | 155 |
| 160 FontLoadHistogram m_histogram; | 156 FontLoadHistogram m_histogram; |
| 161 }; | 157 }; |
| 162 | 158 |
| 163 } // namespace blink | 159 } // namespace blink |
| 164 | 160 |
| 165 #endif // FontFaceSet_h | 161 #endif // FontFaceSet_h |
| OLD | NEW |