Infobar material design refresh: bg color
[chromium-blink-merge.git] / cc / blink / web_animation_curve_common.cc
blob8230fab67eb1a6310ca8bec6642e927869522ad9
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "cc/blink/web_animation_curve_common.h"
7 #include "cc/animation/timing_function.h"
9 namespace cc_blink {
11 scoped_ptr<cc::TimingFunction> CreateTimingFunction(
12 blink::WebCompositorAnimationCurve::TimingFunctionType type) {
13 switch (type) {
14 case blink::WebCompositorAnimationCurve::TimingFunctionTypeEase:
15 return cc::EaseTimingFunction::Create();
16 case blink::WebCompositorAnimationCurve::TimingFunctionTypeEaseIn:
17 return cc::EaseInTimingFunction::Create();
18 case blink::WebCompositorAnimationCurve::TimingFunctionTypeEaseOut:
19 return cc::EaseOutTimingFunction::Create();
20 case blink::WebCompositorAnimationCurve::TimingFunctionTypeEaseInOut:
21 return cc::EaseInOutTimingFunction::Create();
22 case blink::WebCompositorAnimationCurve::TimingFunctionTypeLinear:
23 return nullptr;
25 return nullptr;
28 } // namespace cc_blink