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

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

Issue 2701993002: DO NOT COMMIT: Results of running new (proposed) clang-format on Blink (Closed)
Patch Set: 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) 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 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 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 1000 * (monotonicallyIncreasingTime() - preload->discoveryTime())); 81 1000 * (monotonicallyIncreasingTime() - preload->discoveryTime()));
82 DEFINE_STATIC_LOCAL(CustomCountHistogram, preloadDelayHistogram, 82 DEFINE_STATIC_LOCAL(CustomCountHistogram, preloadDelayHistogram,
83 ("WebCore.PreloadDelayMs", 0, 2000, 20)); 83 ("WebCore.PreloadDelayMs", 0, 2000, 20));
84 preloadDelayHistogram.count(duration); 84 preloadDelayHistogram.count(duration);
85 85
86 Resource* resource = preload->start(m_document); 86 Resource* resource = preload->start(m_document);
87 87
88 if (resource && !resource->isLoaded() && 88 if (resource && !resource->isLoaded() &&
89 preload->resourceType() == Resource::CSSStyleSheet) { 89 preload->resourceType() == Resource::CSSStyleSheet) {
90 Settings* settings = m_document->settings(); 90 Settings* settings = m_document->settings();
91 if (settings && (settings->getCSSExternalScannerNoPreload() || 91 if (settings &&
92 settings->getCSSExternalScannerPreload())) 92 (settings->getCSSExternalScannerNoPreload() ||
93 settings->getCSSExternalScannerPreload()))
93 m_cssPreloaders.insert(new CSSPreloaderResourceClient(resource, this)); 94 m_cssPreloaders.insert(new CSSPreloaderResourceClient(resource, this));
94 } 95 }
95 } 96 }
96 97
97 } // namespace blink 98 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698