| Index: third_party/WebKit/Source/core/html/HTMLLinkElement.cpp
|
| diff --git a/third_party/WebKit/Source/core/html/HTMLLinkElement.cpp b/third_party/WebKit/Source/core/html/HTMLLinkElement.cpp
|
| index b157134262d484d9136cc67ec6aa29bbbd5b3a54..05a54a24e6321238ecf8cc2a8a20342c039790dc 100644
|
| --- a/third_party/WebKit/Source/core/html/HTMLLinkElement.cpp
|
| +++ b/third_party/WebKit/Source/core/html/HTMLLinkElement.cpp
|
| @@ -45,6 +45,19 @@
|
|
|
| namespace blink {
|
|
|
| +namespace {
|
| +WebServiceWorkerUpdateViaCache ParseUpdateViaCache(const AtomicString& value) {
|
| + if (value == "imports")
|
| + return WebServiceWorkerUpdateViaCache::kImports;
|
| + if (value == "all")
|
| + return WebServiceWorkerUpdateViaCache::kAll;
|
| + if (value == "none")
|
| + return WebServiceWorkerUpdateViaCache::kNone;
|
| + // Default value
|
| + return WebServiceWorkerUpdateViaCache::kImports;
|
| +}
|
| +} // namespace
|
| +
|
| using namespace HTMLNames;
|
|
|
| inline HTMLLinkElement::HTMLLinkElement(Document& document,
|
| @@ -102,6 +115,9 @@ void HTMLLinkElement::ParseAttribute(
|
| } else if (name == scopeAttr) {
|
| scope_ = value;
|
| Process();
|
| + } else if (name == updateviacacheAttr) {
|
| + update_via_cache_ = ParseUpdateViaCache(value);
|
| + Process();
|
| } else if (name == disabledAttr) {
|
| UseCounter::Count(GetDocument(), WebFeature::kHTMLLinkElementDisabled);
|
| if (LinkStyle* link = GetLinkStyle())
|
|
|