Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(279)

Side by Side Diff: Source/core/css/FontFaceSet.h

Issue 196383035: Fix promise resolution of FontFaceSet#load() (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: naming Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/css/FontFace.cpp ('k') | Source/core/css/FontFaceSet.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 class FontFaceSet FINAL : public RefCountedSupplement<Document, FontFaceSet>, pu blic ActiveDOMObject, public EventTargetWithInlineData { 61 class FontFaceSet FINAL : public RefCountedSupplement<Document, FontFaceSet>, pu blic ActiveDOMObject, public EventTargetWithInlineData {
62 REFCOUNTED_EVENT_TARGET(FontFaceSet); 62 REFCOUNTED_EVENT_TARGET(FontFaceSet);
63 public: 63 public:
64 virtual ~FontFaceSet(); 64 virtual ~FontFaceSet();
65 65
66 DEFINE_ATTRIBUTE_EVENT_LISTENER(loading); 66 DEFINE_ATTRIBUTE_EVENT_LISTENER(loading);
67 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadingdone); 67 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadingdone);
68 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadingerror); 68 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadingerror);
69 69
70 bool check(const String& font, const String& text, ExceptionState&); 70 bool check(const String& font, const String& text, ExceptionState&);
71 ScriptPromise load(const String& font, const String& text, ExceptionState&); 71 ScriptPromise load(const String& font, const String& text);
72 ScriptPromise ready(); 72 ScriptPromise ready();
73 73
74 void add(FontFace*, ExceptionState&); 74 void add(FontFace*, ExceptionState&);
75 void clear(); 75 void clear();
76 bool remove(FontFace*, ExceptionState&); 76 bool remove(FontFace*, ExceptionState&);
77 void forEach(PassOwnPtr<FontFaceSetForEachCallback>, ScriptValue& thisArg) c onst; 77 void forEach(PassOwnPtr<FontFaceSetForEachCallback>, ScriptValue& thisArg) c onst;
78 void forEach(PassOwnPtr<FontFaceSetForEachCallback>) const; 78 void forEach(PassOwnPtr<FontFaceSetForEachCallback>) const;
79 bool has(FontFace*, ExceptionState&) const; 79 bool has(FontFace*, ExceptionState&) const;
80 80
81 unsigned long size() const; 81 unsigned long size() const;
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 ListHashSet<RefPtr<FontFace> > m_nonCSSConnectedFaces; 147 ListHashSet<RefPtr<FontFace> > m_nonCSSConnectedFaces;
148 148
149 AsyncMethodRunner<FontFaceSet> m_asyncRunner; 149 AsyncMethodRunner<FontFaceSet> m_asyncRunner;
150 150
151 FontLoadHistogram m_histogram; 151 FontLoadHistogram m_histogram;
152 }; 152 };
153 153
154 } // namespace WebCore 154 } // namespace WebCore
155 155
156 #endif // FontFaceSet_h 156 #endif // FontFaceSet_h
OLDNEW
« no previous file with comments | « Source/core/css/FontFace.cpp ('k') | Source/core/css/FontFaceSet.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698