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

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

Issue 2769283004: Remove referrer setter from CSSImageValue (Closed)
Patch Set: Created 3 years, 9 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
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLTableElement.cpp ('k') | no next file » | 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) 1997 Martin Jones (mjones@kde.org) 2 * Copyright (C) 1997 Martin Jones (mjones@kde.org)
3 * (C) 1997 Torben Weis (weis@kde.org) 3 * (C) 1997 Torben Weis (weis@kde.org)
4 * (C) 1998 Waldo Bastian (bastian@kde.org) 4 * (C) 1998 Waldo Bastian (bastian@kde.org)
5 * (C) 1999 Lars Knoll (knoll@kde.org) 5 * (C) 1999 Lars Knoll (knoll@kde.org)
6 * (C) 1999 Antti Koivisto (koivisto@kde.org) 6 * (C) 1999 Antti Koivisto (koivisto@kde.org)
7 * Copyright (C) 2003, 2004, 2005, 2006 Apple Computer, Inc. 7 * Copyright (C) 2003, 2004, 2005, 2006 Apple Computer, Inc.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 MutableStylePropertySet* style) { 54 MutableStylePropertySet* style) {
55 if (name == bgcolorAttr) { 55 if (name == bgcolorAttr) {
56 addHTMLColorToStyle(style, CSSPropertyBackgroundColor, value); 56 addHTMLColorToStyle(style, CSSPropertyBackgroundColor, value);
57 } else if (name == backgroundAttr) { 57 } else if (name == backgroundAttr) {
58 String url = stripLeadingAndTrailingHTMLSpaces(value); 58 String url = stripLeadingAndTrailingHTMLSpaces(value);
59 if (!url.isEmpty()) { 59 if (!url.isEmpty()) {
60 UseCounter::count( 60 UseCounter::count(
61 document(), 61 document(),
62 UseCounter::HTMLTableElementPresentationAttributeBackground); 62 UseCounter::HTMLTableElementPresentationAttributeBackground);
63 CSSImageValue* imageValue = 63 CSSImageValue* imageValue =
64 CSSImageValue::create(url, document().completeURL(url)); 64 CSSImageValue::create(url, document().completeURL(url),
65 imageValue->setReferrer(Referrer(document().outgoingReferrer(), 65 Referrer(document().outgoingReferrer(),
66 document().getReferrerPolicy())); 66 document().getReferrerPolicy()));
67 style->setProperty(CSSProperty(CSSPropertyBackgroundImage, *imageValue)); 67 style->setProperty(CSSProperty(CSSPropertyBackgroundImage, *imageValue));
68 } 68 }
69 } else if (name == valignAttr) { 69 } else if (name == valignAttr) {
70 if (equalIgnoringCase(value, "top")) 70 if (equalIgnoringCase(value, "top"))
71 addPropertyToPresentationAttributeStyle(style, CSSPropertyVerticalAlign, 71 addPropertyToPresentationAttributeStyle(style, CSSPropertyVerticalAlign,
72 CSSValueTop); 72 CSSValueTop);
73 else if (equalIgnoringCase(value, "middle")) 73 else if (equalIgnoringCase(value, "middle"))
74 addPropertyToPresentationAttributeStyle(style, CSSPropertyVerticalAlign, 74 addPropertyToPresentationAttributeStyle(style, CSSPropertyVerticalAlign,
75 CSSValueMiddle); 75 CSSValueMiddle);
76 else if (equalIgnoringCase(value, "bottom")) 76 else if (equalIgnoringCase(value, "bottom"))
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 } 108 }
109 109
110 HTMLTableElement* HTMLTablePartElement::findParentTable() const { 110 HTMLTableElement* HTMLTablePartElement::findParentTable() const {
111 ContainerNode* parent = FlatTreeTraversal::parent(*this); 111 ContainerNode* parent = FlatTreeTraversal::parent(*this);
112 while (parent && !isHTMLTableElement(*parent)) 112 while (parent && !isHTMLTableElement(*parent))
113 parent = FlatTreeTraversal::parent(*parent); 113 parent = FlatTreeTraversal::parent(*parent);
114 return toHTMLTableElement(parent); 114 return toHTMLTableElement(parent);
115 } 115 }
116 116
117 } // namespace blink 117 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLTableElement.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698