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

Side by Side Diff: third_party/WebKit/Source/core/css/FontFaceSet.cpp

Issue 2617103002: Use a new Supplement constructor for Supplement<Document> (Part 1) (Closed)
Patch Set: temp Created 3 years, 11 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
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 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
106 } 106 }
107 } 107 }
108 108
109 DEFINE_TRACE(LoadFontPromiseResolver) { 109 DEFINE_TRACE(LoadFontPromiseResolver) {
110 visitor->trace(m_fontFaces); 110 visitor->trace(m_fontFaces);
111 visitor->trace(m_resolver); 111 visitor->trace(m_resolver);
112 LoadFontCallback::trace(visitor); 112 LoadFontCallback::trace(visitor);
113 } 113 }
114 114
115 FontFaceSet::FontFaceSet(Document& document) 115 FontFaceSet::FontFaceSet(Document& document)
116 : SuspendableObject(&document), 116 : Supplement<Document>(document),
117 SuspendableObject(&document),
117 m_shouldFireLoadingEvent(false), 118 m_shouldFireLoadingEvent(false),
118 m_isLoading(false), 119 m_isLoading(false),
119 m_ready( 120 m_ready(
120 new ReadyProperty(getExecutionContext(), this, ReadyProperty::Ready)), 121 new ReadyProperty(getExecutionContext(), this, ReadyProperty::Ready)),
121 m_asyncRunner(AsyncMethodRunner<FontFaceSet>::create( 122 m_asyncRunner(AsyncMethodRunner<FontFaceSet>::create(
122 this, 123 this,
123 &FontFaceSet::handlePendingEventsAndPromises)) { 124 &FontFaceSet::handlePendingEventsAndPromises)) {
124 suspendIfNeeded(); 125 suspendIfNeeded();
125 } 126 }
126 127
(...skipping 433 matching lines...) Expand 10 before | Expand all | Expand 10 after
560 visitor->trace(m_failedFonts); 561 visitor->trace(m_failedFonts);
561 visitor->trace(m_nonCSSConnectedFaces); 562 visitor->trace(m_nonCSSConnectedFaces);
562 visitor->trace(m_asyncRunner); 563 visitor->trace(m_asyncRunner);
563 EventTargetWithInlineData::trace(visitor); 564 EventTargetWithInlineData::trace(visitor);
564 Supplement<Document>::trace(visitor); 565 Supplement<Document>::trace(visitor);
565 SuspendableObject::trace(visitor); 566 SuspendableObject::trace(visitor);
566 FontFace::LoadFontCallback::trace(visitor); 567 FontFace::LoadFontCallback::trace(visitor);
567 } 568 }
568 569
569 } // namespace blink 570 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698