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

Side by Side Diff: third_party/WebKit/Source/core/css/CSSFontFaceSrcValue.h

Issue 2668903003: Replace WTF::emptyString{16Bit}() with a static global (Closed)
Patch Set: Replace WTF::emptyString{16Bit}() with a static global Created 3 years, 10 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 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 static CSSFontFaceSrcValue* create( 42 static CSSFontFaceSrcValue* create(
43 const String& specifiedResource, 43 const String& specifiedResource,
44 const String& absoluteResource, 44 const String& absoluteResource,
45 ContentSecurityPolicyDisposition shouldCheckContentSecurityPolicy) { 45 ContentSecurityPolicyDisposition shouldCheckContentSecurityPolicy) {
46 return new CSSFontFaceSrcValue(specifiedResource, absoluteResource, false, 46 return new CSSFontFaceSrcValue(specifiedResource, absoluteResource, false,
47 shouldCheckContentSecurityPolicy); 47 shouldCheckContentSecurityPolicy);
48 } 48 }
49 static CSSFontFaceSrcValue* createLocal( 49 static CSSFontFaceSrcValue* createLocal(
50 const String& absoluteResource, 50 const String& absoluteResource,
51 ContentSecurityPolicyDisposition shouldCheckContentSecurityPolicy) { 51 ContentSecurityPolicyDisposition shouldCheckContentSecurityPolicy) {
52 return new CSSFontFaceSrcValue(emptyString(), absoluteResource, true, 52 return new CSSFontFaceSrcValue(emptyString, absoluteResource, true,
53 shouldCheckContentSecurityPolicy); 53 shouldCheckContentSecurityPolicy);
54 } 54 }
55 55
56 const String& resource() const { return m_absoluteResource; } 56 const String& resource() const { return m_absoluteResource; }
57 const String& format() const { return m_format; } 57 const String& format() const { return m_format; }
58 bool isLocal() const { return m_isLocal; } 58 bool isLocal() const { return m_isLocal; }
59 59
60 void setFormat(const String& format) { m_format = format; } 60 void setFormat(const String& format) { m_format = format; }
61 void setReferrer(const Referrer& referrer) { m_referrer = referrer; } 61 void setReferrer(const Referrer& referrer) { m_referrer = referrer; }
62 62
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
118 } 118 }
119 }; 119 };
120 mutable Member<FontResourceHelper> m_fetched; 120 mutable Member<FontResourceHelper> m_fetched;
121 }; 121 };
122 122
123 DEFINE_CSS_VALUE_TYPE_CASTS(CSSFontFaceSrcValue, isFontFaceSrcValue()); 123 DEFINE_CSS_VALUE_TYPE_CASTS(CSSFontFaceSrcValue, isFontFaceSrcValue());
124 124
125 } // namespace blink 125 } // namespace blink
126 126
127 #endif 127 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698