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

Unified Diff: Source/core/svg/animation/SMILTime.h

Issue 499933002: Simplify SMILTime operators (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Move +/- operators to the header. Created 6 years, 4 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 | « no previous file | Source/core/svg/animation/SMILTime.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/svg/animation/SMILTime.h
diff --git a/Source/core/svg/animation/SMILTime.h b/Source/core/svg/animation/SMILTime.h
index 0b439295bd3c43ef35610b8d21da0bba7842ba62..d3a27a21365b6f712d258f2947d953dd35edf809 100644
--- a/Source/core/svg/animation/SMILTime.h
+++ b/Source/core/svg/animation/SMILTime.h
@@ -96,8 +96,8 @@ inline bool operator>=(const SMILTime& a, const SMILTime& b) { return operator>(
inline bool operator<=(const SMILTime& a, const SMILTime& b) { return operator<(a, b) || operator==(a, b); }
inline bool operator<(const SMILTimeWithOrigin& a, const SMILTimeWithOrigin& b) { return a.time() < b.time(); }
-SMILTime operator+(const SMILTime&, const SMILTime&);
-SMILTime operator-(const SMILTime&, const SMILTime&);
+inline SMILTime operator+(const SMILTime& a, const SMILTime& b) { return a.value() + b.value(); }
+inline SMILTime operator-(const SMILTime& a, const SMILTime& b) { return a.value() - b.value(); }
// So multiplying times does not make too much sense but SMIL defines it for duration * repeatCount
SMILTime operator*(const SMILTime&, const SMILTime&);
« no previous file with comments | « no previous file | Source/core/svg/animation/SMILTime.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698