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 thread to check current network. More...
#include <musicnetworkthread.h>
Public Slots | |
void | networkStateChanged () |
Signals | |
void | networkConnectionStateChanged (bool state) |
Public Member Functions | |
void | start () |
void | setBlockNetwork (bool block) |
void | setNetWorkState (bool state) |
bool | isOnline () const |
Private Member Functions | |
MusicNetworkThread () | |
~MusicNetworkThread () | |
Private Attributes | |
QTimer | m_timer |
bool | m_networkState |
The class of thread to check current network.
Definition at line 28 of file musicnetworkthread.h.
|
private |
Object constructor.
Definition at line 11 of file musicnetworkthread.cpp.
References G_CONNECTION_PTR, m_timer, and networkStateChanged().
|
private |
|
inline |
Check current network is on.
Definition at line 48 of file musicnetworkthread.h.
|
signal |
Network connection state changed. default status is true, means connected network.
Referenced by networkStateChanged().
|
slot |
Network connection state changed.
Definition at line 37 of file musicnetworkthread.cpp.
References MusicSettingManager::CloseNetWorkMode, G_SETTING_PTR, m_networkState, NETWORK_REQUEST_ADDRESS, networkConnectionStateChanged(), and TTKConcurrent.
Referenced by MusicNetworkThread(), and start().
void MusicNetworkThread::setBlockNetwork | ( | bool | block | ) |
Set flag wheather to block current network.
Definition at line 32 of file musicnetworkthread.cpp.
References MusicSettingManager::CloseNetWorkMode, and G_SETTING_PTR.
|
inline |
Set current network state.
Definition at line 44 of file musicnetworkthread.h.
void MusicNetworkThread::start | ( | ) |
Strat thread now.
Definition at line 25 of file musicnetworkthread.cpp.
References m_timer, NETWORK_DETECT_INTERVAL, networkStateChanged(), and TTK_INFO_STREAM.
|
private |
Definition at line 74 of file musicnetworkthread.h.
Referenced by networkStateChanged().
|
private |
Definition at line 73 of file musicnetworkthread.h.
Referenced by MusicNetworkThread(), start(), and ~MusicNetworkThread().