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

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

Issue 1189523015: Add use-counters for Client-Hints features (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: style Created 5 years, 6 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) 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 503 matching lines...) Expand 10 before | Expand all | Expand 10 after
514 m_isAppCacheEnabled = true; 514 m_isAppCacheEnabled = true;
515 return; 515 return;
516 } 516 }
517 if (match(tagImpl, metaTag)) { 517 if (match(tagImpl, metaTag)) {
518 const typename Token::Attribute* equivAttribute = token.getAttribute Item(http_equivAttr); 518 const typename Token::Attribute* equivAttribute = token.getAttribute Item(http_equivAttr);
519 if (equivAttribute) { 519 if (equivAttribute) {
520 String equivAttributeValue(equivAttribute->value); 520 String equivAttributeValue(equivAttribute->value);
521 if (equalIgnoringCase(equivAttributeValue, "content-security-pol icy")) 521 if (equalIgnoringCase(equivAttributeValue, "content-security-pol icy"))
522 m_isCSPEnabled = true; 522 m_isCSPEnabled = true;
523 else if (equalIgnoringCase(equivAttributeValue, "accept-ch")) 523 else if (equalIgnoringCase(equivAttributeValue, "accept-ch"))
524 handleAcceptClientHintsHeader(equivAttributeValue, m_clientH intsPreferences); 524 handleAcceptClientHintsHeader(equivAttributeValue, m_clientH intsPreferences, nullptr);
Nate Chapin 2015/06/16 17:10:28 It's not obvious to me why the ResourceFetcher* pa
525 return; 525 return;
526 } 526 }
527 const typename Token::Attribute* nameAttribute = token.getAttributeI tem(nameAttr); 527 const typename Token::Attribute* nameAttribute = token.getAttributeI tem(nameAttr);
528 if (nameAttribute && equalIgnoringCase(String(nameAttribute->value), "viewport")) { 528 if (nameAttribute && equalIgnoringCase(String(nameAttribute->value), "viewport")) {
529 const typename Token::Attribute* contentAttribute = token.getAtt ributeItem(contentAttr); 529 const typename Token::Attribute* contentAttribute = token.getAtt ributeItem(contentAttr);
530 if (contentAttribute) 530 if (contentAttribute)
531 handleMetaViewport(String(contentAttribute->value), m_docume ntParameters.get()); 531 handleMetaViewport(String(contentAttribute->value), m_docume ntParameters.get());
532 return; 532 return;
533 } 533 }
534 } 534 }
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
609 mediaValues = givenMediaValues; 609 mediaValues = givenMediaValues;
610 else 610 else
611 mediaValues = MediaValuesCached::create(*document); 611 mediaValues = MediaValuesCached::create(*document);
612 ASSERT(mediaValues->isSafeToSendToAnotherThread()); 612 ASSERT(mediaValues->isSafeToSendToAnotherThread());
613 defaultViewportMinWidth = document->viewportDefaultMinWidth(); 613 defaultViewportMinWidth = document->viewportDefaultMinWidth();
614 viewportMetaZeroValuesQuirk = document->settings() && document->settings()-> viewportMetaZeroValuesQuirk(); 614 viewportMetaZeroValuesQuirk = document->settings() && document->settings()-> viewportMetaZeroValuesQuirk();
615 viewportMetaEnabled = document->settings() && document->settings()->viewport MetaEnabled(); 615 viewportMetaEnabled = document->settings() && document->settings()->viewport MetaEnabled();
616 } 616 }
617 617
618 } 618 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698