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 desktop wallpaper thread. More...
#include <musicdesktopwallpaperthread.h>
Public Slots | |
void | start () |
void | stop () |
void | timeout () |
Signals | |
void | updateBackground (const QPixmap &pix) |
Public Member Functions | |
MusicDesktopWallpaperThread (QObject *parent=nullptr) | |
~MusicDesktopWallpaperThread () | |
void | setInterval (int msec) |
bool | isRunning () const |
void | setRandom (bool random) |
void | setImagePath (const QStringList &list) |
Private Attributes | |
bool | m_run |
bool | m_random |
int | m_currentImageIndex |
QTimer * | m_timer |
QStringList | m_path |
The class of the desktop wallpaper thread.
Definition at line 37 of file musicdesktopwallpaperthread.h.
|
explicit |
Object constructor.
Definition at line 9 of file musicdesktopwallpaperthread.cpp.
References TTK::initRandom(), m_timer, setInterval(), timeout(), and TTK_DN_S2MS.
MusicDesktopWallpaperThread::~MusicDesktopWallpaperThread | ( | ) |
Object destructor.
Definition at line 22 of file musicdesktopwallpaperthread.cpp.
bool MusicDesktopWallpaperThread::isRunning | ( | ) | const |
State is running.
Definition at line 33 of file musicdesktopwallpaperthread.cpp.
References m_run.
Referenced by MusicLrcContainerForWallpaper::start().
void MusicDesktopWallpaperThread::setImagePath | ( | const QStringList & | list | ) |
Set image path.
Definition at line 42 of file musicdesktopwallpaperthread.cpp.
References m_path.
Referenced by MusicLrcContainerForWallpaper::start().
void MusicDesktopWallpaperThread::setInterval | ( | int | msec | ) |
Set time interval.
Definition at line 28 of file musicdesktopwallpaperthread.cpp.
References m_timer.
Referenced by MusicDesktopWallpaperThread().
void MusicDesktopWallpaperThread::setRandom | ( | bool | random | ) |
Set random mode check.
Definition at line 38 of file musicdesktopwallpaperthread.cpp.
References m_random, and TTK::random().
|
slot |
Strat thread now.
Definition at line 70 of file musicdesktopwallpaperthread.cpp.
References m_run, m_timer, and timeout().
Referenced by MusicLrcContainerForWallpaper::start().
|
slot |
Stop and quit current thread.
Definition at line 77 of file musicdesktopwallpaperthread.cpp.
References m_run, and m_timer.
Referenced by ~MusicDesktopWallpaperThread().
|
slot |
Thread run now.
random mode
Definition at line 83 of file musicdesktopwallpaperthread.cpp.
References G_BACKGROUND_PTR, m_currentImageIndex, m_path, MusicBackgroundImage::m_pix, m_random, m_run, MusicExtractWrapper::outputSkin(), TTK::random(), and updateBackground().
Referenced by MusicDesktopWallpaperThread(), MusicLrcContainerForWallpaper::start(), and start().
|
signal |
Update background pixmap.
Referenced by timeout().
|
private |
Definition at line 102 of file musicdesktopwallpaperthread.h.
Referenced by timeout().
|
private |
Definition at line 104 of file musicdesktopwallpaperthread.h.
Referenced by setImagePath(), and timeout().
|
private |
Definition at line 101 of file musicdesktopwallpaperthread.h.
Referenced by setRandom(), and timeout().
|
private |
Definition at line 101 of file musicdesktopwallpaperthread.h.
Referenced by isRunning(), start(), stop(), and timeout().
|
private |
Definition at line 103 of file musicdesktopwallpaperthread.h.
Referenced by MusicDesktopWallpaperThread(), setInterval(), start(), stop(), and ~MusicDesktopWallpaperThread().