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

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

Issue 640593002: Replace FINAL and OVERRIDE with their C++11 counterparts in Source/core/[css|rendering|clipboard] (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebased the patch Created 6 years, 2 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
« no previous file with comments | « Source/core/css/FontFaceCache.h ('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 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 class Dictionary; 51 class Dictionary;
52 class Document; 52 class Document;
53 class ExceptionState; 53 class ExceptionState;
54 class Font; 54 class Font;
55 class FontFaceCache; 55 class FontFaceCache;
56 class FontResource; 56 class FontResource;
57 class FontsReadyPromiseResolver; 57 class FontsReadyPromiseResolver;
58 class ExecutionContext; 58 class ExecutionContext;
59 59
60 #if ENABLE(OILPAN) 60 #if ENABLE(OILPAN)
61 class FontFaceSet FINAL : public GarbageCollectedFinalized<FontFaceSet>, public HeapSupplement<Document>, public ActiveDOMObject, public EventTargetWithInlineDa ta { 61 class FontFaceSet final : public GarbageCollectedFinalized<FontFaceSet>, public HeapSupplement<Document>, public ActiveDOMObject, public EventTargetWithInlineDa ta {
62 USING_GARBAGE_COLLECTED_MIXIN(FontFaceSet); 62 USING_GARBAGE_COLLECTED_MIXIN(FontFaceSet);
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); 73 DEFINE_ATTRIBUTE_EVENT_LISTENER(loading);
74 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadingdone); 74 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadingdone);
75 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadingerror); 75 DEFINE_ATTRIBUTE_EVENT_LISTENER(loadingerror);
76 76
77 bool check(const String& font, const String& text, ExceptionState&); 77 bool check(const String& font, const String& text, ExceptionState&);
78 ScriptPromise load(ScriptState*, const String& font, const String& text); 78 ScriptPromise load(ScriptState*, const String& font, const String& text);
79 ScriptPromise ready(ScriptState*); 79 ScriptPromise ready(ScriptState*);
80 80
81 void add(FontFace*, ExceptionState&); 81 void add(FontFace*, ExceptionState&);
82 void clear(); 82 void clear();
83 bool remove(FontFace*, ExceptionState&); 83 bool remove(FontFace*, ExceptionState&);
84 void forEach(FontFaceSetForEachCallback*, const ScriptValue& thisArg) const; 84 void forEach(FontFaceSetForEachCallback*, const ScriptValue& thisArg) const;
85 void forEach(FontFaceSetForEachCallback*) const; 85 void forEach(FontFaceSetForEachCallback*) const;
86 bool has(FontFace*, ExceptionState&) const; 86 bool has(FontFace*, ExceptionState&) const;
87 87
88 unsigned long size() const; 88 unsigned long size() const;
89 AtomicString status() const; 89 AtomicString status() const;
90 90
91 virtual ExecutionContext* executionContext() const OVERRIDE; 91 virtual ExecutionContext* executionContext() const override;
92 virtual const AtomicString& interfaceName() const OVERRIDE; 92 virtual const AtomicString& interfaceName() const override;
93 93
94 Document* document() const; 94 Document* document() const;
95 95
96 void didLayout(); 96 void didLayout();
97 void beginFontLoading(FontFace*); 97 void beginFontLoading(FontFace*);
98 void fontLoaded(FontFace*); 98 void fontLoaded(FontFace*);
99 void loadError(FontFace*); 99 void loadError(FontFace*);
100 100
101 // ActiveDOMObject 101 // ActiveDOMObject
102 virtual void suspend() OVERRIDE; 102 virtual void suspend() override;
103 virtual void resume() OVERRIDE; 103 virtual void resume() override;
104 virtual void stop() OVERRIDE; 104 virtual void stop() override;
105 105
106 static PassRefPtrWillBeRawPtr<FontFaceSet> from(Document&); 106 static PassRefPtrWillBeRawPtr<FontFaceSet> from(Document&);
107 static void didLayout(Document&); 107 static void didLayout(Document&);
108 108
109 void addFontFacesToFontFaceCache(FontFaceCache*, CSSFontSelector*); 109 void addFontFacesToFontFaceCache(FontFaceCache*, CSSFontSelector*);
110 110
111 #if ENABLE(OILPAN) 111 #if ENABLE(OILPAN)
112 virtual void trace(Visitor*) OVERRIDE; 112 virtual void trace(Visitor*) override;
113 #endif 113 #endif
114 114
115 private: 115 private:
116 static PassRefPtrWillBeRawPtr<FontFaceSet> create(Document& document) 116 static PassRefPtrWillBeRawPtr<FontFaceSet> create(Document& document)
117 { 117 {
118 return adoptRefWillBeNoop(new FontFaceSet(document)); 118 return adoptRefWillBeNoop(new FontFaceSet(document));
119 } 119 }
120 120
121 class FontLoadHistogram { 121 class FontLoadHistogram {
122 public: 122 public:
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
156 WillBeHeapListHashSet<RefPtrWillBeMember<FontFace> > m_nonCSSConnectedFaces; 156 WillBeHeapListHashSet<RefPtrWillBeMember<FontFace> > m_nonCSSConnectedFaces;
157 157
158 AsyncMethodRunner<FontFaceSet> m_asyncRunner; 158 AsyncMethodRunner<FontFaceSet> m_asyncRunner;
159 159
160 FontLoadHistogram m_histogram; 160 FontLoadHistogram m_histogram;
161 }; 161 };
162 162
163 } // namespace blink 163 } // namespace blink
164 164
165 #endif // FontFaceSet_h 165 #endif // FontFaceSet_h
OLDNEW
« no previous file with comments | « Source/core/css/FontFaceCache.h ('k') | Source/core/css/FontFaceSet.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698