MCPcopy Create free account
hub / github.com/PlotJuggler/PlotJuggler / animateHover

Method animateHover

pj_widgets/src/ScrubberBase.cpp:458–471  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

456}
457
458void ScrubberBase::animateHover(bool entering) {
459 if (!hover_animation_) {
460 hover_animation_ = new QVariantAnimation(this);
461 hover_animation_->setEasingCurve(QEasingCurve::OutCubic);
462 connect(hover_animation_, &QVariantAnimation::valueChanged, this, [this](const QVariant& v) {
463 setHoverAlphaInternal(v.toReal());
464 });
465 }
466 hover_animation_->stop();
467 hover_animation_->setDuration(kHoverFadeMs);
468 hover_animation_->setStartValue(hover_alpha_);
469 hover_animation_->setEndValue(entering ? 1.0 : 0.0);
470 hover_animation_->start();
471}
472
473} // namespace PJ

Callers

nothing calls this directly

Calls 3

toRealMethod · 0.80
stopMethod · 0.45
startMethod · 0.45

Tested by

no test coverage detected