TTKMusicPlayer
3.7.0.0
TTKMusicPlayer imitates Kugou UI, the music player uses of qmmp core library based on Qt for windows and linux
|
The class of the label transition animation. More...
#include <musictransitionanimationlabel.h>
Public Types | |
enum | Module { Module::FadeEffect, Module::BlindsEffect, Module::CubeEffect, Module::WaterEffect, Module::LeftToRightEffect, Module::TopToBottomEffect } |
Public Slots | |
void | setPixmap (const QPixmap &pix) |
Public Member Functions | |
MusicTransitionAnimationLabel (QWidget *parent=nullptr) | |
~MusicTransitionAnimationLabel () | |
void | setAnimation (bool on) |
bool | noAnimation () const |
const QPixmap & | rendererPixmap () const |
void | stop () |
Private Slots | |
void | valueChanged (const QVariant &value) |
void | animationFinished () |
Private Member Functions | |
virtual void | paintEvent (QPaintEvent *event) overridefinal |
Private Attributes | |
Module | m_type |
bool | m_isAnimating |
int | m_currentValue |
bool | m_noAnimationSet |
QPixmap | m_rendererPixmap |
QPixmap | m_currentPixmap |
QPixmap | m_previousPixmap |
QPropertyAnimation * | m_animation |
QAlgorithm::SharpeImage * | m_cubeWave |
QAlgorithm::SharpeImage * | m_waterWave |
The class of the label transition animation.
Definition at line 34 of file musictransitionanimationlabel.h.
|
strong |
Enumerator | |
---|---|
FadeEffect | |
BlindsEffect | |
CubeEffect | |
WaterEffect | |
LeftToRightEffect | |
TopToBottomEffect |
Definition at line 39 of file musictransitionanimationlabel.h.
|
explicit |
Object constructor.
Definition at line 9 of file musictransitionanimationlabel.cpp.
References animationFinished(), TTK::initRandom(), m_animation, and valueChanged().
MusicTransitionAnimationLabel::~MusicTransitionAnimationLabel | ( | ) |
Object destructor.
Definition at line 30 of file musictransitionanimationlabel.cpp.
References m_animation.
|
privateslot |
Animation finished.
Definition at line 121 of file musictransitionanimationlabel.cpp.
References m_currentPixmap, m_currentValue, m_isAnimating, and m_rendererPixmap.
Referenced by MusicTransitionAnimationLabel(), and stop().
|
inline |
Get no animation state.
Definition at line 65 of file musictransitionanimationlabel.h.
|
finaloverrideprivatevirtual |
Override the widget event.
Definition at line 130 of file musictransitionanimationlabel.cpp.
References BlindsEffect, CubeEffect, FadeEffect, LeftToRightEffect, m_cubeWave, m_currentPixmap, m_currentValue, m_isAnimating, m_previousPixmap, m_rendererPixmap, m_type, m_waterWave, QAlgorithm::SharpeImage::render(), TopToBottomEffect, and WaterEffect.
const QPixmap & MusicTransitionAnimationLabel::rendererPixmap | ( | ) | const |
Get renderer pixmap image.
Definition at line 35 of file musictransitionanimationlabel.cpp.
References m_rendererPixmap.
|
inline |
Set no animation to start.
Definition at line 61 of file musictransitionanimationlabel.h.
|
slot |
Override the setPixmap function.
Definition at line 49 of file musictransitionanimationlabel.cpp.
References BlindsEffect, CubeEffect, FadeEffect, QAlgorithm::SharpeImage::input(), LeftToRightEffect, m_animation, m_cubeWave, m_currentPixmap, m_isAnimating, m_noAnimationSet, m_previousPixmap, m_rendererPixmap, m_type, m_waterWave, QtLablePixmap, TTK::random(), stop(), TopToBottomEffect, TTKStaticCast, and WaterEffect.
Referenced by MusicScreenSaverBackgroundWidget::backgroundTimeout(), and MusicLrcContainerForWallpaper::updateBackground().
void MusicTransitionAnimationLabel::stop | ( | ) |
Stop renderer pixmap animation.
Definition at line 40 of file musictransitionanimationlabel.cpp.
References animationFinished(), and m_animation.
Referenced by setPixmap().
|
privateslot |
Animation value changed.
Definition at line 115 of file musictransitionanimationlabel.cpp.
References m_currentValue.
Referenced by MusicTransitionAnimationLabel().
|
private |
Definition at line 105 of file musictransitionanimationlabel.h.
Referenced by MusicTransitionAnimationLabel(), setPixmap(), stop(), and ~MusicTransitionAnimationLabel().
|
private |
Definition at line 107 of file musictransitionanimationlabel.h.
Referenced by paintEvent(), and setPixmap().
|
private |
Definition at line 104 of file musictransitionanimationlabel.h.
Referenced by animationFinished(), paintEvent(), and setPixmap().
|
private |
Definition at line 101 of file musictransitionanimationlabel.h.
Referenced by animationFinished(), paintEvent(), and valueChanged().
|
private |
Definition at line 100 of file musictransitionanimationlabel.h.
Referenced by animationFinished(), paintEvent(), and setPixmap().
|
private |
Definition at line 102 of file musictransitionanimationlabel.h.
Referenced by setPixmap().
|
private |
Definition at line 104 of file musictransitionanimationlabel.h.
Referenced by paintEvent(), and setPixmap().
|
private |
Definition at line 103 of file musictransitionanimationlabel.h.
Referenced by animationFinished(), paintEvent(), rendererPixmap(), and setPixmap().
|
private |
Definition at line 99 of file musictransitionanimationlabel.h.
Referenced by paintEvent(), and setPixmap().
|
private |
Definition at line 108 of file musictransitionanimationlabel.h.
Referenced by paintEvent(), and setPixmap().