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

Side by Side Diff: third_party/WebKit/Source/core/html/HTMLElement.h

Issue 2528673003: Rework the "rules for parsing dimension values" implementation (Closed)
Patch Set: Rebase; clarify comment. 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * Copyright (C) 2004-2007, 2009, 2014 Apple Inc. All rights reserved. 4 * Copyright (C) 2004-2007, 2009, 2014 Apple Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 int offsetLeftForBinding(); 115 int offsetLeftForBinding();
116 int offsetTopForBinding(); 116 int offsetTopForBinding();
117 int offsetWidthForBinding(); 117 int offsetWidthForBinding();
118 int offsetHeightForBinding(); 118 int offsetHeightForBinding();
119 119
120 Element* unclosedOffsetParent(); 120 Element* unclosedOffsetParent();
121 121
122 protected: 122 protected:
123 HTMLElement(const QualifiedName& tagName, Document&, ConstructionType); 123 HTMLElement(const QualifiedName& tagName, Document&, ConstructionType);
124 124
125 enum AllowPercentage { DontAllowPercentageValues, AllowPercentageValues };
125 void addHTMLLengthToStyle(MutableStylePropertySet*, 126 void addHTMLLengthToStyle(MutableStylePropertySet*,
126 CSSPropertyID, 127 CSSPropertyID,
127 const String& value); 128 const String& value,
129 AllowPercentage = AllowPercentageValues);
128 void addHTMLColorToStyle(MutableStylePropertySet*, 130 void addHTMLColorToStyle(MutableStylePropertySet*,
129 CSSPropertyID, 131 CSSPropertyID,
130 const String& color); 132 const String& color);
131 133
132 void applyAlignmentAttributeToStyle(const AtomicString&, 134 void applyAlignmentAttributeToStyle(const AtomicString&,
133 MutableStylePropertySet*); 135 MutableStylePropertySet*);
134 void applyBorderAttributeToStyle(const AtomicString&, 136 void applyBorderAttributeToStyle(const AtomicString&,
135 MutableStylePropertySet*); 137 MutableStylePropertySet*);
136 138
137 void parseAttribute(const QualifiedName&, 139 void parseAttribute(const QualifiedName&,
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
231 inline bool isElementOfType<const thisType>(const HTMLElement& element) { \ 233 inline bool isElementOfType<const thisType>(const HTMLElement& element) { \
232 return is##thisType(element); \ 234 return is##thisType(element); \
233 } \ 235 } \
234 DEFINE_ELEMENT_TYPE_CASTS_WITH_FUNCTION(thisType) 236 DEFINE_ELEMENT_TYPE_CASTS_WITH_FUNCTION(thisType)
235 237
236 } // namespace blink 238 } // namespace blink
237 239
238 #include "core/HTMLElementTypeHelpers.h" 240 #include "core/HTMLElementTypeHelpers.h"
239 241
240 #endif // HTMLElement_h 242 #endif // HTMLElement_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLDimensionTest.cpp ('k') | third_party/WebKit/Source/core/html/HTMLElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698