| Index: third_party/WebKit/Source/core/css/cssom/ComputedStylePropertyMap.cpp
|
| diff --git a/third_party/WebKit/Source/core/css/cssom/ComputedStylePropertyMap.cpp b/third_party/WebKit/Source/core/css/cssom/ComputedStylePropertyMap.cpp
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..ca336d0c9d507f54dd91b86ef856b9274e1f4555
|
| --- /dev/null
|
| +++ b/third_party/WebKit/Source/core/css/cssom/ComputedStylePropertyMap.cpp
|
| @@ -0,0 +1,29 @@
|
| +// Copyright 2016 the Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#include "core/css/cssom/ComputedStylePropertyMap.h"
|
| +
|
| +#include "core/css/CSSComputedStyleDeclaration.h"
|
| +#include "core/css/cssom/StyleValueFactory.h"
|
| +
|
| +namespace blink {
|
| +
|
| +StylePropertyMap::StyleValueVector ComputedStylePropertyMap::getAll(CSSPropertyID propertyID)
|
| +{
|
| + CSSValue* cssValue = m_computedStyleDeclaration->getPropertyCSSValueInternal(propertyID);
|
| + if (!cssValue)
|
| + return StylePropertyMap::StyleValueVector();
|
| + return cssValueToStyleValueVector(propertyID, *cssValue);
|
| +}
|
| +
|
| +Vector<String> ComputedStylePropertyMap::getProperties()
|
| +{
|
| + Vector<String> result;
|
| + for (unsigned i = 0; i < m_computedStyleDeclaration->length(); i++) {
|
| + result.append(m_computedStyleDeclaration->item(i));
|
| + }
|
| + return result;
|
| +}
|
| +
|
| +} // namespace blink
|
|
|