TTKMusicPlayer
4.1.3.0
TTKMusicPlayer imitates Kugou UI, the music player uses of qmmp core library based on Qt for windows and linux
|
The class of the wall paper lrc container. More...
#include <musiclrccontainerforwallpaper.h>
Public Slots | |
void | changeCurrentLrcColor () |
void | updateBackground (const QPixmap &pix) |
![]() | |
void | currentLrcCustom () |
void | changeCurrentLrcColor (QAction *action) |
void | changeCurrentLrcColor (int index) |
void | searchMusicLrcs () |
void | showLrcMakedWidget () |
void | linkLrcStateChanged () |
Public Member Functions | |
MusicLrcContainerForWallpaper (QWidget *parent=nullptr) | |
~MusicLrcContainerForWallpaper () | |
virtual void | startDrawLrc () overridefinal |
virtual void | stopDrawLrc () overridefinal |
virtual void | applyParameter () overridefinal |
void | setLrcAnalysisModel (MusicLrcAnalysis *analysis) |
void | updateCurrentLrc (qint64 time) |
void | updateCurrentLrc (const QString &text) |
void | start (bool immediate) |
![]() | |
MusicLrcContainer (QWidget *parent=nullptr) | |
~MusicLrcContainer () | |
void | setLinearGradientColor (MusicLrcColor::Color color) |
void | setLinearGradientColor (const MusicLrcColor &color) |
void | setCurrentSongName (const QString &name) |
void | setCurrentTime (qint64 time, qint64 total) |
qint64 | totalTime () const |
void | setLrcAnalysisModel (MusicLrcAnalysis *analysis) |
MusicLrcAnalysis * | lrcAnalysisModel () const |
Private Slots | |
void | updateAnimationLrc () |
Private Member Functions | |
void | initCurrentLrc (const QString &str) |
void | setItemStyleSheet (int index, int size, int transparent) |
Private Attributes | |
int | m_animationFreshTime |
MusicVLayoutAnimationWidget * | m_layoutWidget |
MusicDesktopWallpaperThread * | m_wallThread |
MusicTransitionAnimationLabel * | m_background |
Additional Inherited Members | |
![]() | |
void | currentLrcUpdated () |
void | showCurrentLrcSetting () |
void | showCurrentLrcColorSetting () |
void | maskLinearGradientColorChanged () |
void | linearGradientColorChanged () |
![]() | |
void | clearAllMusicLRCManager () |
![]() | |
bool | m_linkLocalLrc |
qint64 | m_currentTime |
qint64 | m_totalTime |
QString | m_currentSongName |
QString | m_containerType |
MusicLrcAnalysis * | m_lrcAnalysis |
QList< MusicLrcManager * > | m_lrcManagers |
MusicLrcSearchWidget * | m_lrcSearchWidget |
The class of the wall paper lrc container.
Definition at line 31 of file musiclrccontainerforwallpaper.h.
|
explicit |
Object constructor.
Definition at line 8 of file musiclrccontainerforwallpaper.cpp.
References MusicLayoutAnimationWidget::connectTo(), LRC_WALLPAPER_TPYE, m_background, MusicLrcContainer::m_containerType, m_layoutWidget, m_wallThread, and updateBackground().
MusicLrcContainerForWallpaper::~MusicLrcContainerForWallpaper | ( | ) |
Object destructor.
Definition at line 40 of file musiclrccontainerforwallpaper.cpp.
References MusicLrcContainer::clearAllMusicLRCManager(), and m_wallThread.
|
finaloverridevirtual |
Set setting parameter.
Reimplemented from MusicLrcContainer.
Definition at line 57 of file musiclrccontainerforwallpaper.cpp.
References G_SETTING_PTR, LRC_PER_WIDTH, MusicLrcContainer::m_lrcManagers, MUSIC_LRC_INTERIOR_MAX_LINE, MusicSettingManager::ScreenSize, setItemStyleSheet(), MusicLrcManager::setLrcFontSize(), MusicLrcManagerForInterior::setLrcPerWidth(), MusicLrcManager::setY(), and TTKObjectCast.
Referenced by MusicRightAreaWidget::applyParameter(), changeCurrentLrcColor(), and MusicRightAreaWidget::containerForWallpaperClicked().
|
slot |
Change current lrc linear color.
Definition at line 153 of file musiclrccontainerforwallpaper.cpp.
References applyParameter().
|
private |
Init current lrc when the first show.
Definition at line 175 of file musiclrccontainerforwallpaper.cpp.
References MusicLrcAnalysis::lineMax(), MusicLrcContainer::m_lrcAnalysis, MusicLrcContainer::m_lrcManagers, and MUSIC_LRC_INTERIOR_MAX_LINE.
Referenced by setLrcAnalysisModel().
|
private |
Set per lrc line style sheet by index and size and transparent.
Definition at line 184 of file musiclrccontainerforwallpaper.cpp.
References G_SETTING_PTR, MusicLrcContainer::m_lrcManagers, TTK::readColorConfig(), MusicLrcManagerForInterior::setFontSize(), MusicLrcManager::setFontTransparent(), MusicLrcContainer::setLinearGradientColor(), MusicLrcManagerForInterior::setTransparent(), TTK_RN_MAX, TTKObjectCast, and TTKStaticCast.
Referenced by applyParameter().
void MusicLrcContainerForWallpaper::setLrcAnalysisModel | ( | MusicLrcAnalysis * | analysis | ) |
Set lrc analysis model.
Definition at line 98 of file musiclrccontainerforwallpaper.cpp.
References MusicLayoutAnimationWidget::addStretch(), MusicLayoutAnimationWidget::addWidget(), initCurrentLrc(), m_layoutWidget, MusicLrcContainer::m_lrcManagers, MUSIC_LRC_INTERIOR_MAX_LINE, MusicLrcContainer::setLrcAnalysisModel(), and start().
Referenced by MusicRightAreaWidget::containerForWallpaperClicked().
void MusicLrcContainerForWallpaper::start | ( | bool | immediate | ) |
Strat now.
Definition at line 135 of file musiclrccontainerforwallpaper.cpp.
References G_BACKGROUND_PTR, MusicDesktopWallpaperThread::isRunning(), m_wallThread, MusicDesktopWallpaperThread::setImagePath(), MusicDesktopWallpaperThread::start(), and MusicDesktopWallpaperThread::timeout().
Referenced by MusicRightAreaWidget::loadCurrentSongLrc(), setLrcAnalysisModel(), and updateCurrentLrc().
|
finaloverridevirtual |
Start timer clock to draw lrc.
Implements MusicLrcContainer.
Definition at line 46 of file musiclrccontainerforwallpaper.cpp.
References MusicLrcContainer::m_lrcManagers, and MUSIC_LRC_INTERIOR_MAX_LINE.
Referenced by MusicRightAreaWidget::startDrawLrc().
|
finaloverridevirtual |
Stop timer clock to draw lrc.
Implements MusicLrcContainer.
Definition at line 51 of file musiclrccontainerforwallpaper.cpp.
References m_layoutWidget, MusicLrcContainer::m_lrcManagers, MUSIC_LRC_INTERIOR_MAX_LINE, and MusicLayoutAnimationWidget::stop().
Referenced by MusicRightAreaWidget::loadCurrentSongLrc(), and MusicRightAreaWidget::stopDrawLrc().
|
privateslot |
Animation finished.
Definition at line 165 of file musiclrccontainerforwallpaper.cpp.
References MusicLrcAnalysis::lineMax(), m_animationFreshTime, MusicLrcContainer::m_lrcAnalysis, MusicLrcContainer::m_lrcManagers, MUSIC_LRC_INTERIOR_MAX_LINE, and MusicLrcAnalysis::text().
|
slot |
Update background pixmap.
Definition at line 158 of file musiclrccontainerforwallpaper.cpp.
References G_SETTING_PTR, m_background, MusicSettingManager::ScreenSize, and MusicTransitionAnimationLabel::setPixmap().
Referenced by MusicLrcContainerForWallpaper().
void MusicLrcContainerForWallpaper::updateCurrentLrc | ( | qint64 | time | ) |
Update current lrc by given time.
Definition at line 115 of file musiclrccontainerforwallpaper.cpp.
References MusicLrcAnalysis::isValid(), m_animationFreshTime, m_layoutWidget, MusicLrcContainer::m_lrcAnalysis, start(), and MusicVLayoutAnimationWidget::start().
Referenced by MusicRightAreaWidget::loadCurrentSongLrc(), and MusicRightAreaWidget::updateCurrentLrc().
void MusicLrcContainerForWallpaper::updateCurrentLrc | ( | const QString & | text | ) |
Update current lrc by given text.
Definition at line 126 of file musiclrccontainerforwallpaper.cpp.
References MusicLrcContainer::m_lrcManagers, and MUSIC_LRC_INTERIOR_MAX_LINE.
|
private |
Definition at line 101 of file musiclrccontainerforwallpaper.h.
Referenced by updateAnimationLrc(), and updateCurrentLrc().
|
private |
Definition at line 104 of file musiclrccontainerforwallpaper.h.
Referenced by MusicLrcContainerForWallpaper(), and updateBackground().
|
private |
Definition at line 102 of file musiclrccontainerforwallpaper.h.
Referenced by MusicLrcContainerForWallpaper(), setLrcAnalysisModel(), stopDrawLrc(), and updateCurrentLrc().
|
private |
Definition at line 103 of file musiclrccontainerforwallpaper.h.
Referenced by MusicLrcContainerForWallpaper(), start(), and ~MusicLrcContainerForWallpaper().