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

Side by Side Diff: third_party/WebKit/Source/core/html/parser/HTMLPreloadScanner.cpp

Issue 2496343002: Support as=<UPPERCASE VALUE> for link preloads in preload scanner (Closed)
Patch Set: add another test case Created 4 years 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 | « no previous file | third_party/WebKit/Source/core/html/parser/HTMLPreloadScannerTest.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) 2008 Apple Inc. All Rights Reserved. 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved.
3 * Copyright (C) 2009 Torch Mobile, Inc. http://www.torchmobile.com/ 3 * Copyright (C) 2009 Torch Mobile, Inc. http://www.torchmobile.com/
4 * Copyright (C) 2010 Google Inc. All Rights Reserved. 4 * Copyright (C) 2010 Google Inc. All Rights Reserved.
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 331 matching lines...) Expand 10 before | Expand all | Expand 10 after
342 m_linkIsPreconnect = rel.isPreconnect(); 342 m_linkIsPreconnect = rel.isPreconnect();
343 m_linkIsPreload = rel.isLinkPreload(); 343 m_linkIsPreload = rel.isLinkPreload();
344 m_linkIsImport = rel.isImport(); 344 m_linkIsImport = rel.isImport();
345 } else if (match(attributeName, mediaAttr)) { 345 } else if (match(attributeName, mediaAttr)) {
346 m_matched &= mediaAttributeMatches(*m_mediaValues, attributeValue); 346 m_matched &= mediaAttributeMatches(*m_mediaValues, attributeValue);
347 } else if (match(attributeName, crossoriginAttr)) { 347 } else if (match(attributeName, crossoriginAttr)) {
348 setCrossOrigin(attributeValue); 348 setCrossOrigin(attributeValue);
349 } else if (match(attributeName, nonceAttr)) { 349 } else if (match(attributeName, nonceAttr)) {
350 setNonce(attributeValue); 350 setNonce(attributeValue);
351 } else if (match(attributeName, asAttr)) { 351 } else if (match(attributeName, asAttr)) {
352 m_asAttributeValue = attributeValue; 352 m_asAttributeValue = attributeValue.lower();
353 } else if (match(attributeName, typeAttr)) { 353 } else if (match(attributeName, typeAttr)) {
354 m_matched &= MIMETypeRegistry::isSupportedStyleSheetMIMEType( 354 m_matched &= MIMETypeRegistry::isSupportedStyleSheetMIMEType(
355 ContentType(attributeValue).type()); 355 ContentType(attributeValue).type());
356 } else if (!m_referrerPolicySet && 356 } else if (!m_referrerPolicySet &&
357 match(attributeName, referrerpolicyAttr) && 357 match(attributeName, referrerpolicyAttr) &&
358 !attributeValue.isNull()) { 358 !attributeValue.isNull()) {
359 m_referrerPolicySet = true; 359 m_referrerPolicySet = true;
360 SecurityPolicy::referrerPolicyFromString(attributeValue, 360 SecurityPolicy::referrerPolicyFromString(attributeValue,
361 &m_referrerPolicy); 361 &m_referrerPolicy);
362 } 362 }
(...skipping 540 matching lines...) Expand 10 before | Expand all | Expand 10 after
903 defaultViewportMinWidth = document->viewportDefaultMinWidth(); 903 defaultViewportMinWidth = document->viewportDefaultMinWidth();
904 viewportMetaZeroValuesQuirk = 904 viewportMetaZeroValuesQuirk =
905 document->settings() && 905 document->settings() &&
906 document->settings()->viewportMetaZeroValuesQuirk(); 906 document->settings()->viewportMetaZeroValuesQuirk();
907 viewportMetaEnabled = 907 viewportMetaEnabled =
908 document->settings() && document->settings()->viewportMetaEnabled(); 908 document->settings() && document->settings()->viewportMetaEnabled();
909 referrerPolicy = document->getReferrerPolicy(); 909 referrerPolicy = document->getReferrerPolicy();
910 } 910 }
911 911
912 } // namespace blink 912 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/parser/HTMLPreloadScannerTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698