chromium/ui/compositor/layer_animation_element.cc

// Copyright 2012 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "ui/compositor/layer_animation_element.h"

#include <utility>

#include "base/compiler_specific.h"
#include "base/strings/stringprintf.h"
#include "cc/animation/animation_id_provider.h"
#include "cc/animation/keyframe_model.h"
#include "ui/compositor/float_animation_curve_adapter.h"
#include "ui/compositor/layer.h"
#include "ui/compositor/layer_animation_delegate.h"
#include "ui/compositor/layer_animator.h"
#include "ui/compositor/scoped_animation_duration_scale_mode.h"
#include "ui/compositor/transform_animation_curve_adapter.h"
#include "ui/gfx/animation/tween.h"
#include "ui/gfx/interpolated_transform.h"

namespace ui {

namespace {

// Pause -----------------------------------------------------------------------
class Pause : public LayerAnimationElement {};

// InterpolatedTransformTransition ---------------------------------------------

class InterpolatedTransformTransition : public LayerAnimationElement {};

// BoundsTransition ------------------------------------------------------------

class BoundsTransition : public LayerAnimationElement {};

// VisibilityTransition --------------------------------------------------------

class VisibilityTransition : public LayerAnimationElement {};

// BrightnessTransition --------------------------------------------------------

class BrightnessTransition : public LayerAnimationElement {};

// GrayscaleTransition ---------------------------------------------------------

class GrayscaleTransition : public LayerAnimationElement {};

// ColorTransition -------------------------------------------------------------

class ColorTransition : public LayerAnimationElement {};

// ClipRectTransition ----------------------------------------------------------

class ClipRectTransition : public LayerAnimationElement {};

// RoundedCornersTransition ----------------------------------------------------

class RoundedCornersTransition : public LayerAnimationElement {};

// GradientMaskTransition ----------------------------------------------------

class GradientMaskTransition : public LayerAnimationElement {};

// ThreadedLayerAnimationElement -----------------------------------------------

class ThreadedLayerAnimationElement : public LayerAnimationElement {};

// ThreadedOpacityTransition ---------------------------------------------------

class ThreadedOpacityTransition : public ThreadedLayerAnimationElement {};

// ThreadedTransformTransition -------------------------------------------------

class ThreadedTransformTransition : public ThreadedLayerAnimationElement {};

}  // namespace

// LayerAnimationElement::TargetValue ------------------------------------------

LayerAnimationElement::TargetValue::TargetValue()
    :{}

LayerAnimationElement::TargetValue::TargetValue(
    const LayerAnimationDelegate* delegate)
    :{}

// LayerAnimationElement -------------------------------------------------------

LayerAnimationElement::LayerAnimationElement(AnimatableProperties properties,
                                             base::TimeDelta duration)
    :{}

LayerAnimationElement::LayerAnimationElement(
    const LayerAnimationElement& element)
    :{}

LayerAnimationElement::~LayerAnimationElement() = default;

void LayerAnimationElement::Start(LayerAnimationDelegate* delegate,
                                  int animation_group_id) {}

bool LayerAnimationElement::Progress(base::TimeTicks now,
                                     LayerAnimationDelegate* delegate) {}

bool LayerAnimationElement::IsFinished(base::TimeTicks time,
                                       base::TimeDelta* total_duration) {}

bool LayerAnimationElement::ProgressToEnd(LayerAnimationDelegate* delegate) {}

void LayerAnimationElement::GetTargetValue(TargetValue* target) const {}

bool LayerAnimationElement::IsThreaded(LayerAnimationDelegate* delegate) const {}

void LayerAnimationElement::Abort(LayerAnimationDelegate* delegate) {}

void LayerAnimationElement::RequestEffectiveStart(
    LayerAnimationDelegate* delegate) {}

std::string LayerAnimationElement::ToString() const {}

void LayerAnimationElement::UpdateKeyframeModelId() {}

std::string LayerAnimationElement::DebugName() const {}

// static
LayerAnimationElement::AnimatableProperty
LayerAnimationElement::ToAnimatableProperty(cc::TargetProperty::Type property) {}

// static
std::string LayerAnimationElement::AnimatablePropertiesToString(
    AnimatableProperties properties) {}

// static
base::TimeDelta LayerAnimationElement::GetEffectiveDuration(
    const base::TimeDelta& duration) {}

// static
std::unique_ptr<LayerAnimationElement>
LayerAnimationElement::CreateTransformElement(const gfx::Transform& transform,
                                              base::TimeDelta duration) {}

// static
std::unique_ptr<LayerAnimationElement>
LayerAnimationElement::CreateInterpolatedTransformElement(
    std::unique_ptr<InterpolatedTransform> interpolated_transform,
    base::TimeDelta duration) {}

// static
std::unique_ptr<LayerAnimationElement>
LayerAnimationElement::CreateBoundsElement(const gfx::Rect& bounds,
                                           base::TimeDelta duration) {}

// static
std::unique_ptr<LayerAnimationElement>
LayerAnimationElement::CreateOpacityElement(float opacity,
                                            base::TimeDelta duration) {}

// static
std::unique_ptr<LayerAnimationElement>
LayerAnimationElement::CreateVisibilityElement(bool visibility,
                                               base::TimeDelta duration) {}

// static
std::unique_ptr<LayerAnimationElement>
LayerAnimationElement::CreateBrightnessElement(float brightness,
                                               base::TimeDelta duration) {}

// static
std::unique_ptr<LayerAnimationElement>
LayerAnimationElement::CreateGrayscaleElement(float grayscale,
                                              base::TimeDelta duration) {}

// static
std::unique_ptr<LayerAnimationElement>
LayerAnimationElement::CreatePauseElement(AnimatableProperties properties,
                                          base::TimeDelta duration) {}

// static
std::unique_ptr<LayerAnimationElement>
LayerAnimationElement::CreateColorElement(SkColor color,
                                          base::TimeDelta duration) {}

std::unique_ptr<LayerAnimationElement>
LayerAnimationElement::CreateClipRectElement(const gfx::Rect& clip_rect,
                                             base::TimeDelta duration) {}

std::unique_ptr<LayerAnimationElement>
LayerAnimationElement::CreateRoundedCornersElement(
    const gfx::RoundedCornersF& rounded_corners,
    base::TimeDelta duration) {}

std::unique_ptr<LayerAnimationElement>
LayerAnimationElement::CreateGradientMaskElement(
    const gfx::LinearGradient& gradient_mask,
    base::TimeDelta duration) {}

}  // namespace ui