MCPcopy Index your code
hub / github.com/Audio4Linux/JDSP4Linux / AnimatedJDSPIcon

Method AnimatedJDSPIcon

src/interface/AnimatedJdspIcon.cpp:3–28  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1#include "AnimatedJdspIcon.h"
2
3AnimatedJDSPIcon::AnimatedJDSPIcon(QWidget *parent)
4 : QWidget(parent)
5{
6 svgItem->setGeometry(0, 0, 64, 64);
7 svgItemU->setGeometry(0, 0, 64, 64);
8 svgItemL->setGeometry(0, 0, 64, 64);
9 this->setGeometry(0, 0, 64, 64);
10 this->setFixedSize(64, 64);
11
12 svgItemU->hide();
13 svgItemL->hide();
14
15 group = new QParallelAnimationGroup(this);
16 QPropertyAnimation *upper = new QPropertyAnimation(svgItemU, "geometry");
17 upper->setDuration(700);
18 upper->setEasingCurve(QEasingCurve::Type::OutCirc);
19 upper->setStartValue(QRect(0, -64, 64, 64));
20 upper->setEndValue(QRect(0, 0, 64, 64));
21 group->addAnimation(upper);
22 QPropertyAnimation *lower = new QPropertyAnimation(svgItemL, "geometry");
23 lower->setDuration(700);
24 lower->setEasingCurve(QEasingCurve::Type::OutCirc);
25 lower->setStartValue(QRect(0, 128, 64, 64));
26 lower->setEndValue(QRect(0, 0, 64, 64));
27 group->addAnimation(lower);
28}
29
30AnimatedJDSPIcon::~AnimatedJDSPIcon()
31{

Callers

nothing calls this directly

Calls 4

QRectClass · 0.85
hideMethod · 0.80
setDurationMethod · 0.80
setEasingCurveMethod · 0.80

Tested by

no test coverage detected