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

Unified Diff: third_party/WebKit/Source/wtf/RefVector.h

Issue 1680803003: Add additive animation support for CSS property background-position (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove redundant braces Created 4 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/core/style/ComputedStyle.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/wtf/RefVector.h
diff --git a/third_party/WebKit/Source/wtf/RefVector.h b/third_party/WebKit/Source/wtf/RefVector.h
index 0571fc7acf408c5a7f20a9bb001b018a932987a4..824aa44c47b07372dd7fbe057764f9d62858b552 100644
--- a/third_party/WebKit/Source/wtf/RefVector.h
+++ b/third_party/WebKit/Source/wtf/RefVector.h
@@ -15,7 +15,9 @@ template <typename T>
class RefVector : public RefCounted<RefVector<T>> {
public:
static PassRefPtr<RefVector> create() { return adoptRef(new RefVector<T>); }
- PassRefPtr<RefVector> copy() { return adoptRef(new RefVector<T>(*this)); }
+ static PassRefPtr<RefVector> create(const Vector<T>& vector) { return adoptRef(new RefVector<T>(vector)); }
+ static PassRefPtr<RefVector> create(Vector<T>&& vector) { return adoptRef(new RefVector<T>(vector)); }
+ PassRefPtr<RefVector> copy() { return create(vector()); }
const T& operator[](size_t i) const { return m_vector[i]; }
T& operator[](size_t i) { return m_vector[i]; }
@@ -33,7 +35,8 @@ public:
private:
Vector<T> m_vector;
RefVector() { }
- RefVector(const RefVector& o) : m_vector(o.m_vector) { }
+ RefVector(const Vector<T>& vector) : m_vector(vector) { }
+ RefVector(Vector<T>&& vector) : m_vector(vector) { }
};
} // namespace blink
« no previous file with comments | « third_party/WebKit/Source/core/style/ComputedStyle.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698