예제 #1
0
WebAnimation WebAnimation::fadeAnimation(const WebString& name, float from, float to, double duration)
{
    WebAnimation tmp;
    tmp.d->name = String(name.impl());
    tmp.d->animation = Animation::create();
    tmp.d->animation->setDuration(duration);
    tmp.d->keyframes = KeyframeValueList(AnimatedPropertyOpacity);
    tmp.d->keyframes.insert(new FloatAnimationValue(0, from));
    tmp.d->keyframes.insert(new FloatAnimationValue(1.0, to));

    return tmp;
}
예제 #2
0
void WebOverlay::removeAnimation(const WebString& name)
{
    d->removeAnimation(String(PassRefPtr<StringImpl>(name.impl())));
}