MCPcopy Create free account
hub / github.com/KDE/kwin / animate

Method animate

src/scripting/scriptedeffect.cpp:486–498  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

484}
485
486quint64 ScriptedEffect::animate(KWin::EffectWindow *window, KWin::AnimationEffect::Attribute attribute,
487 int ms, const QJSValue &to, const QJSValue &from, uint metaData, int curve,
488 int delay, bool fullScreen, bool keepAlive, uint shaderId)
489{
490 QEasingCurve qec;
491 if (curve < QEasingCurve::Custom) {
492 qec.setType(static_cast<QEasingCurve::Type>(curve));
493 } else if (curve == GaussianCurve) {
494 qec.setCustomType(qecGaussian);
495 }
496 return AnimationEffect::animate(window, attribute, metaData, std::chrono::milliseconds(ms), fpx2FromScriptValue(to), qec,
497 delay, fpx2FromScriptValue(from), fullScreen, keepAlive, findShader(shaderId));
498}
499
500QJSValue ScriptedEffect::animate(const QJSValue &object)
501{

Callers 5

animationTest.jsFile · 0.80
effect.jsFile · 0.80
onWindowAddedMethod · 0.80
main.jsFile · 0.80

Calls 2

fpx2FromScriptValueFunction · 0.85
setTypeMethod · 0.45

Tested by

no test coverage detected