Chromium Code Reviews| Index: third_party/WebKit/Source/core/style/StyleVariableData.cpp |
| diff --git a/third_party/WebKit/Source/core/style/StyleVariableData.cpp b/third_party/WebKit/Source/core/style/StyleVariableData.cpp |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..2efc9c97fafd1a41208e998611daf23ff5df0b2d |
| --- /dev/null |
| +++ b/third_party/WebKit/Source/core/style/StyleVariableData.cpp |
| @@ -0,0 +1,27 @@ |
| +// Copyright 2015 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 "config.h" |
| +#include "core/style/StyleVariableData.h" |
| + |
| +#include "core/style/DataEquivalency.h" |
| + |
| +namespace blink { |
| + |
| +bool StyleVariableData::operator==(const StyleVariableData& other) const |
| +{ |
| + if (m_data.size() != other.m_data.size()) { |
| + return false; |
| + } |
| + |
| + for (const auto iter : m_data) { |
|
Timothy Loh
2015/12/17 04:22:56
const auto& probably
shans
2015/12/17 05:14:14
Done.
|
| + RefPtr<CSSVariableData> otherData = other.m_data.get(iter.key); |
| + if (!dataEquivalent(iter.value, otherData)) |
| + return false; |
| + } |
| + |
| + return true; |
| +} |
| + |
| +} // namespace blink |