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

Unified Diff: Source/core/animation/AnimationNodeTiming.cpp

Issue 466323002: IDL: Use Nullable for union type return value (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 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
Index: Source/core/animation/AnimationNodeTiming.cpp
diff --git a/Source/core/animation/AnimationNodeTiming.cpp b/Source/core/animation/AnimationNodeTiming.cpp
index b43fba6aa1da4e14df64abd6fbfffa1f01338646..ee06f07e6969c9bd8261cfdff94d331dded44440 100644
--- a/Source/core/animation/AnimationNodeTiming.cpp
+++ b/Source/core/animation/AnimationNodeTiming.cpp
@@ -65,18 +65,16 @@ double AnimationNodeTiming::iterations()
// and bindings/tests/results/V8TestInterface.cpp.
// FIXME: It might be possible to have 'duration' defined as an attribute in the idl.
// If possible, fix will be in a follow-up patch.
-void AnimationNodeTiming::getDuration(String propertyName, bool& element0Enabled, double& element0, bool& element1Enabled, String& element1)
+void AnimationNodeTiming::getDuration(String propertyName, Nullable<double>& element0, Nullable<String>& element1)
{
if (propertyName != "duration")
return;
if (std::isnan(m_parent->specifiedTiming().iterationDuration)) {
- element1Enabled = true;
- element1 = "auto";
+ element1.set("auto");
return;
}
- element0Enabled = true;
- element0 = m_parent->specifiedTiming().iterationDuration * 1000;
+ element0.set(m_parent->specifiedTiming().iterationDuration * 1000);
return;
}

Powered by Google App Engine
This is Rietveld 408576698