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

Side by Side Diff: third_party/WebKit/Source/core/loader/resource/FontResource.h

Issue 2550663002: Allow creating font data while FontResource is revalidating (Closed)
Patch Set: rebase Created 3 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008 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 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 55
56 void setRevalidatingRequest(const ResourceRequest&) override; 56 void setRevalidatingRequest(const ResourceRequest&) override;
57 57
58 void allClientsAndObserversRemoved() override; 58 void allClientsAndObserversRemoved() override;
59 void startLoadLimitTimers(); 59 void startLoadLimitTimers();
60 60
61 void setCORSFailed() override { m_corsFailed = true; } 61 void setCORSFailed() override { m_corsFailed = true; }
62 bool isCORSFailed() const { return m_corsFailed; } 62 bool isCORSFailed() const { return m_corsFailed; }
63 String otsParsingMessage() const { return m_otsParsingMessage; } 63 String otsParsingMessage() const { return m_otsParsingMessage; }
64 64
65 bool hasCustomFontData() const { return static_cast<bool>(m_fontData); }
65 bool ensureCustomFontData(); 66 bool ensureCustomFontData();
66 FontPlatformData platformDataFromCustomData( 67 FontPlatformData platformDataFromCustomData(
67 float size, 68 float size,
68 bool bold, 69 bool bold,
69 bool italic, 70 bool italic,
70 FontOrientation = FontOrientation::Horizontal, 71 FontOrientation = FontOrientation::Horizontal,
71 FontVariationSettings* = nullptr); 72 FontVariationSettings* = nullptr);
72 73
73 // Returns true if the loading priority of the remote font resource can be 74 // Returns true if the loading priority of the remote font resource can be
74 // lowered. The loading priority of the font can be lowered only if the 75 // lowered. The loading priority of the font can be lowered only if the
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
140 // Only the RemoteFontFaceSources clients can prevent lowering of loading 141 // Only the RemoteFontFaceSources clients can prevent lowering of loading
141 // priority of the remote fonts. Set the default to true to prevent 142 // priority of the remote fonts. Set the default to true to prevent
142 // other clients from incorrectly returning false. 143 // other clients from incorrectly returning false.
143 return true; 144 return true;
144 } 145 }
145 }; 146 };
146 147
147 } // namespace blink 148 } // namespace blink
148 149
149 #endif 150 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698