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 song share widget. More...
#include <musicsongsharingwidget.h>
Classes | |
struct | Item |
Public Types | |
enum | Module { Module::Song, Module::Movie, Module::Artist, Module::Album, Module::Playlist, Module::Null } |
Public Slots | |
void | textAreaChanged () |
void | confirmButtonClicked () |
void | shareTimeout () |
void | downLoadFinished (const QByteArray &bytes) |
![]() | |
void | backgroundChanged () |
virtual int | exec () |
void | show () |
Public Member Functions | |
MusicSongSharingWidget (QWidget *parent=nullptr) | |
~MusicSongSharingWidget () | |
void | initialize (Module type, const MusicSongSharingWidget::Item &data) |
![]() | |
MusicAbstractMoveDialog (QWidget *parent=nullptr) | |
MusicAbstractMoveDialog (bool transparent, QWidget *parent=nullptr) | |
~MusicAbstractMoveDialog () | |
![]() | |
TTKAbstractMoveDialog (QWidget *parent=nullptr) | |
TTKAbstractMoveDialog (bool transparent, QWidget *parent=nullptr) | |
void | drawWindowShadow (bool show) |
void | blockOption (bool block) |
Private Member Functions | |
void | sendToShare (const QString &playUrl, const QString &imageUrl) |
void | sendToShare (const QString &a, const QString &b, const QString &c) |
Private Attributes | |
Ui::MusicSongSharingWidget * | m_ui |
Module | m_type |
QRCodeQWidget * | m_qrCodeWidget |
MusicSongSharingWidget::Item | m_data |
Additional Inherited Members | |
![]() | |
void | setBackgroundPixmap (const QSize &size) |
MusicWidgetRenderer () | |
void | setBackgroundLabel (QLabel *label) |
The class of the song share widget.
Definition at line 57 of file musicsongsharingwidget.h.
|
strong |
Enumerator | |
---|---|
Song |
song type |
Movie |
Movie type |
Artist |
artist type |
Album |
album type |
Playlist |
playlist type |
Null |
null type |
Definition at line 62 of file musicsongsharingwidget.h.
|
explicit |
Object constructor.
Definition at line 12 of file musicsongsharingwidget.cpp.
References confirmButtonClicked(), m_qrCodeWidget, m_ui, MusicWidgetRenderer::setBackgroundLabel(), QRCodeQWidget::setIcon(), QRCodeQWidget::setMargin(), textAreaChanged(), TTK::UI::TextEditStyle01, and TTK::UI::ToolButtonStyle04.
MusicSongSharingWidget::~MusicSongSharingWidget | ( | ) |
Object destructor.
Definition at line 49 of file musicsongsharingwidget.cpp.
References m_qrCodeWidget, and m_ui.
|
slot |
Confirm button clicked.
Definition at line 76 of file musicsongsharingwidget.cpp.
References Album, Artist, TTKSemaphoreLoop::exec(), G_DOWNLOAD_QUERY_PTR, MusicAbstractQueryRequest::isEmpty(), MusicAbstractQueryRequest::items(), KG_AL_SHARE, KG_AR_SHARE, KG_MV_SHARE, KG_PL_SHARE, KG_SG_SHARE, KW_AL_SHARE, KW_AR_SHARE, KW_MV_SHARE, KW_PL_SHARE, KW_SG_SHARE, MusicSongSharingWidget::Item::m_cover, TTK::MusicSongInformation::m_coverUrl, m_data, MusicSongSharingWidget::Item::m_id, MusicSongSharingWidget::Item::m_server, TTK::MusicSongInformation::m_songId, m_type, m_ui, MusicAbstractQueryRequest::Meta, Movie, Playlist, MusicAbstractQueryRequest::queryServer(), sendToShare(), MusicAbstractQueryRequest::setQueryMode(), shareTimeout(), Song, MusicAbstractQueryRequest::startToSearch(), TTK_DN_S2MS, TTK_SIGNLE_SHOT, TTK_SLOT, WY_AL_SHARE, WY_AR_SHARE, WY_MV_SHARE, WY_PL_SHARE, and WY_SG_SHARE.
Referenced by MusicSongSharingWidget().
|
slot |
Download data from net finished.
Definition at line 209 of file musicsongsharingwidget.cpp.
References m_ui, and TTK_ERROR_STREAM.
Referenced by initialize().
void MusicSongSharingWidget::initialize | ( | Module | type, |
const MusicSongSharingWidget::Item & | data | ||
) |
Set current data to share.
Definition at line 55 of file musicsongsharingwidget.cpp.
References ART_DIR_FULL, downLoadFinished(), TTK::Widget::elidedText(), G_DOWNLOAD_QUERY_PTR, TTK::generateSongArtist(), TTK::isCoverValid(), MusicSongSharingWidget::Item::m_cover, m_data, MusicSongSharingWidget::Item::m_name, m_type, m_ui, name, SKN_FILE, and MusicCoverRequest::startToRequest().
Referenced by MusicAbstractItemQueryWidget::shareButtonClicked(), MusicVideoPlayWidget::shareButtonClicked(), MusicAbstractSongsListTableWidget::showPlayedSongSharedWidget(), MusicAbstractSongsListTableWidget::showSongSharedWidget(), and MusicIdentifySongWidget::showSongShareWidget().
|
private |
Send to shared on web.
Definition at line 132 of file musicsongsharingwidget.cpp.
References m_qrCodeWidget, m_ui, TTK::Algorithm::mdII(), MDII_SHR_KEY, TTK::Url::openUrl(), QQ_SHARE, QZONE_SHARE, QRCodeQWidget::setText(), SINA_SHARE, TTK_DN_S2MS, TTK_SIGNLE_SHOT, and TTK_SLOT.
Referenced by confirmButtonClicked(), and sendToShare().
|
private |
Send to shared on web.
Definition at line 164 of file musicsongsharingwidget.cpp.
References MusicSongSharingWidget::Item::m_cover, m_data, MusicSongSharingWidget::Item::m_id, MusicSongSharingWidget::Item::m_server, TTK::Algorithm::mdII(), MDII_SHR_KEY, QUERY_KG_INTERFACE, QUERY_KW_INTERFACE, QUERY_WY_INTERFACE, sendToShare(), shareTimeout(), TTK_DN_S2MS, TTK_SIGNLE_SHOT, and TTK_SLOT.
|
slot |
Query url time out, that means share failed.
Definition at line 127 of file musicsongsharingwidget.cpp.
References MusicToastLabel::popup().
Referenced by confirmButtonClicked(), and sendToShare().
|
slot |
User custom the current share text.
Definition at line 188 of file musicsongsharingwidget.cpp.
References m_ui, and TTK::max().
Referenced by MusicSongSharingWidget().
|
private |
Definition at line 126 of file musicsongsharingwidget.h.
Referenced by confirmButtonClicked(), initialize(), and sendToShare().
|
private |
Definition at line 125 of file musicsongsharingwidget.h.
Referenced by MusicSongSharingWidget(), sendToShare(), and ~MusicSongSharingWidget().
|
private |
Definition at line 124 of file musicsongsharingwidget.h.
Referenced by confirmButtonClicked(), and initialize().
|
private |
Definition at line 123 of file musicsongsharingwidget.h.
Referenced by confirmButtonClicked(), downLoadFinished(), initialize(), MusicSongSharingWidget(), sendToShare(), textAreaChanged(), and ~MusicSongSharingWidget().