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 songs container widget. More...
#include <musicsongscontainerwidget.h>
Public Member Functions | |
MusicSongsContainerWidget (QWidget *parent=nullptr) | |
~MusicSongsContainerWidget () | |
bool | addMusicItemList (const MusicSongItemList &items) |
void | appendMusicItemList (const MusicSongItemList &items) |
const MusicSongItemList & | items () const |
void | importMusicSongsByUrl (const QString &path, int playlistRow) |
void | importMusicSongsByPath (const QStringList &files, int playlistRow) |
QStringList | musicSongsFileName (int index) const |
QStringList | musicSongsFilePath (int index) const |
int | mapSongIndexByFilePath (int playlistRow, const QString &path) const |
QString | mapFilePathBySongIndex (int playlistRow, int index) const |
void | removeSearchResult (int &row) |
int | playRowIndex () const |
void | setCurrentSongTreeIndex (int index) |
void | playLocation (int index) |
void | selectRow (int index) |
void | updateDurationLabel (const QString ¤t, const QString &total) const |
Public Member Functions inherited from MusicSongsToolBoxWidget | |
MusicSongsToolBoxWidget (QWidget *parent=nullptr) | |
void | setSongSort (QWidget *item, MusicSongSort *sort) |
int | makeValidIndex () const |
Public Member Functions inherited from MusicFunctionToolBoxWidget | |
MusicFunctionToolBoxWidget (QWidget *parent=nullptr) | |
~MusicFunctionToolBoxWidget () | |
void | addCellItem (QWidget *item, const QString &text) |
void | removeItem (QWidget *item) |
void | swapItem (int start, int end) |
void | setTitle (QWidget *item, const QString &text) |
void | resizeScrollIndex (int index) const |
int | currentIndex () const |
int | count () const |
Private Slots | |
void | showSearchWidget () |
void | sliderValueChanaged (int value) |
void | deleteFloatWidget () |
Private Member Functions | |
virtual void | resizeEvent (QResizeEvent *event) overridefinal |
virtual void | contextMenuEvent (QContextMenuEvent *event) overridefinal |
virtual void | dragEnterEvent (QDragEnterEvent *event) overridefinal |
virtual void | dragMoveEvent (QDragMoveEvent *event) overridefinal |
virtual void | dropEvent (QDropEvent *event) overridefinal |
bool | isSearchPlayIndex () const |
void | closeSearchWidget () |
void | closeSearchWidgetInNeed () |
void | checkCurrentNameExist (QString &name) |
void | addNewRowItem (const QString &name) |
void | createWidgetItem (MusicSongItem *item) |
void | setItemTitle (MusicSongItem *item) |
void | setInputModule (QObject *object) const |
void | resizeWindow () |
void | updatePlayedList (int start, int end) |
Private Member Functions inherited from MusicItemSearchInterface< MusicSongItemList > | |
MusicItemSearchInterface () | |
bool | hasSearchResult () const |
void | clearSearchResult () |
void | mappedSearchRow (int pos, int &row) const |
Private Attributes | |
int | m_playRowIndex |
int | m_lastSearchIndex |
int | m_selectDeleteIndex |
MusicSongsToolBoxMaskWidget * | m_listMaskWidget |
MusicSongsListFunctionWidget * | m_listFunctionWidget |
MusicSongSearchDialog * | m_songSearchWidget |
Private Attributes inherited from MusicItemSearchInterface< MusicSongItemList > | |
MusicSongItemList | m_containerItems |
int | m_searchResultLevel |
TTKSearchItems | m_searchResultItems |
Additional Inherited Members | |
Protected Member Functions inherited from MusicFunctionToolBoxWidget | |
virtual void | mousePressEvent (QMouseEvent *event) overridefinal |
int | foundMappedIndex (int index) |
Protected Attributes inherited from MusicFunctionToolBoxWidget | |
int | m_currentIndex |
int | m_itemIndexRaise |
QVBoxLayout * | m_layout |
QScrollArea * | m_scrollArea |
QWidget * | m_contentsWidget |
MusicToolBoxWidgetItemList | m_itemList |
Private Types inherited from MusicItemSearchInterface< MusicSongItemList > | |
using | TTKSearchItems = QMap< int, TTKIntList > |
using | MusicItemSearchInterfaceClass = MusicItemSearchInterface< MusicSongItemList > |
The class of the songs container widget.
Definition at line 33 of file musicsongscontainerwidget.h.
|
explicit |
Object constructor.
Definition at line 22 of file musicsongscontainerwidget.cpp.
References G_CONNECTION_PTR, MusicFunctionToolBoxWidget::itemIndexChanged(), m_listMaskWidget, MusicFunctionToolBoxWidget::m_scrollArea, setInputModule(), and sliderValueChanaged().
MusicSongsContainerWidget::~MusicSongsContainerWidget | ( | ) |
Object destructor.
Definition at line 43 of file musicsongscontainerwidget.cpp.
References G_CONNECTION_PTR, MusicItemSearchInterface< MusicSongItemList >::m_containerItems, m_listFunctionWidget, m_listMaskWidget, and m_songSearchWidget.
bool MusicSongsContainerWidget::addMusicItemList | ( | const MusicSongItemList & | items | ) |
Add music datas into container.
Definition at line 56 of file musicsongscontainerwidget.cpp.
References createWidgetItem(), items(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicSongItem::m_itemIndex, MusicSongItem::m_itemName, MUSIC_LOVEST_LIST, MUSIC_NETWORK_LIST, MUSIC_NORMAL_LIST, MUSIC_RECENT_LIST, and qAsConst.
Referenced by MusicApplication::readSystemConfigFromFile().
|
slot |
Add new play list item.
Definition at line 358 of file musicsongscontainerwidget.cpp.
References checkCurrentNameExist(), ITEM_MAX_COUNT, MusicItemSearchInterface< MusicSongItemList >::m_containerItems, and name.
Referenced by contextMenuEvent(), and setInputModule().
|
private |
Add new play list item by name.
Definition at line 1140 of file musicsongscontainerwidget.cpp.
References createWidgetItem(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicSongItem::m_itemName, and name.
|
slot |
Add current network music buffer to playlist.
when download finished just play it at once
Definition at line 720 of file musicsongscontainerwidget.cpp.
References MusicApplication::instance(), MusicResultDataItem::m_category, MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicResultDataItem::m_count, MusicResultDataItem::m_description, MusicResultDataItem::m_id, MusicSongItem::m_itemWidget, MusicResultDataItem::m_name, MusicResultDataItem::m_nickName, MusicSongItem::m_songs, MusicResultDataItem::m_updateTime, TTK::Algorithm::md5(), MUSIC_NETWORK_LIST, MUSIC_PLAY_NOW, MusicApplication::playIndexClicked(), MusicFunctionToolBoxWidget::setCurrentIndex(), setItemTitle(), and MusicAbstractSongsListTableWidget::updateSongsList().
|
slot |
Add or remove music list song to lovest list by row.
if current play list contains, call main add and remove function
Add to lovest list
Remove to lovest list
Definition at line 684 of file musicsongscontainerwidget.cpp.
References MusicApplication::addSongToLovestList(), MusicItemSearchInterface< MusicSongItemList >::hasSearchResult(), MusicApplication::instance(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicFunctionToolBoxWidget::m_currentIndex, MusicSongItem::m_itemWidget, m_playRowIndex, MusicSongItem::m_songs, MUSIC_LOVEST_LIST, MusicSong::path(), MusicSongsListPlayTableWidget::removeItems(), MusicApplication::removeLoveItemAt(), setItemTitle(), TTKObjectCast, and MusicSongsListPlayTableWidget::updateSongsList().
Referenced by createWidgetItem().
|
slot |
Add current selected song to play list.
just play it at once
Definition at line 745 of file musicsongscontainerwidget.cpp.
References importMusicSongsByPath(), MusicApplication::instance(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicSongItem::m_songs, MusicSongsToolBoxWidget::makeValidIndex(), MusicApplication::playIndexClicked(), MusicToastLabel::popup(), and MusicFunctionToolBoxWidget::setCurrentIndex().
|
slot |
Add music to played list.
Definition at line 520 of file musicsongscontainerwidget.cpp.
References MusicPlayedListPopWidget::append(), MusicFunctionToolBoxWidget::foundMappedIndex(), MusicPlayedListPopWidget::instance(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicSongItem::m_itemIndex, and MusicSongItem::m_songs.
Referenced by setInputModule().
|
slot |
Add music to played list and play later.
Definition at line 508 of file musicsongscontainerwidget.cpp.
References MusicFunctionToolBoxWidget::foundMappedIndex(), MusicPlayedListPopWidget::insert(), MusicPlayedListPopWidget::instance(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicSongItem::m_itemIndex, and MusicSongItem::m_songs.
Referenced by setInputModule().
void MusicSongsContainerWidget::appendMusicItemList | ( | const MusicSongItemList & | items | ) |
Append music datas into container.
Definition at line 117 of file musicsongscontainerwidget.cpp.
References checkCurrentNameExist(), createWidgetItem(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicSongItem::m_itemIndex, MusicFunctionToolBoxWidget::m_itemIndexRaise, and MusicSongItem::m_itemName.
Referenced by MusicApplication::importSongsItemList().
Open rename selected play list item widget.
Definition at line 455 of file musicsongscontainerwidget.cpp.
References MusicFunctionToolBoxWidget::foundMappedIndex(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicSongItem::m_itemName, name, and setItemTitle().
Referenced by setInputModule().
|
private |
Check current name exist.
Definition at line 1116 of file musicsongscontainerwidget.cpp.
References ITEM_MAX_COUNT, MusicItemSearchInterface< MusicSongItemList >::m_containerItems, name, and qAsConst.
Referenced by addNewRowItem(), and appendMusicItemList().
|
private |
Close searched text widget.
Definition at line 1100 of file musicsongscontainerwidget.cpp.
References MusicSongSearchDialog::close(), and m_songSearchWidget.
Referenced by closeSearchWidgetInNeed(), and removeSearchResult().
|
private |
Close searched text widget in need.
Definition at line 1108 of file musicsongscontainerwidget.cpp.
References closeSearchWidget(), and MusicItemSearchInterface< MusicSongItemList >::hasSearchResult().
Referenced by deleteRowItemAll(), importMusicSongsByPath(), importMusicSongsByUrl(), selectRow(), and songListSortBy().
|
finaloverrideprivatevirtual |
Definition at line 1084 of file musicsongscontainerwidget.cpp.
References addNewRowItem(), TTK::Widget::adjustMenuPosition(), deleteRowItems(), MusicApplication::instance(), ITEM_MIN_COUNT, MusicItemSearchInterface< MusicSongItemList >::m_containerItems, TTK::UI::MenuStyle02, showLrcDownloadBatchWidget(), and showSongCheckToolsWidget().
|
private |
Create widget item.
connect to items
Definition at line 1148 of file musicsongscontainerwidget.cpp.
References MusicFunctionToolBoxWidget::addCellItem(), addSongToLovestList(), MusicFunctionToolBoxWidget::foundMappedIndex(), isCurrentPlaylistRow(), isSearchedResultEmpty(), itemIndexSwaped(), MusicSongItem::m_itemIndex, MusicFunctionToolBoxWidget::m_itemIndexRaise, MusicFunctionToolBoxWidget::m_itemList, MusicSongItem::m_itemName, MusicSongItem::m_itemWidget, MusicFunctionToolBoxWidget::m_scrollArea, MusicSongItem::m_songs, MusicSongItem::m_sort, removeItemAt(), setInputModule(), MusicSmoothMovingTableWidget::setMovedScrollBar(), MusicAbstractSongsListTableWidget::setPlaylistRow(), MusicAbstractSongsListTableWidget::setSongsList(), MusicSongsListPlayTableWidget::setSongSort(), MusicSongsToolBoxWidget::setSongSort(), MusicFunctionToolBoxWidget::setTitle(), showFloatWidget(), songListSortBy(), and TTK_NORMAL_LEVEL.
Referenced by addMusicItemList(), addNewRowItem(), and appendMusicItemList().
|
privateslot |
Delete the float function widget.
Definition at line 1014 of file musicsongscontainerwidget.cpp.
References m_listFunctionWidget.
Referenced by showFloatWidget().
|
slot |
Delete selected play list item.
Definition at line 368 of file musicsongscontainerwidget.cpp.
References MusicAbstractMoveDialog::exec(), MusicFunctionToolBoxWidget::foundMappedIndex(), MusicApplication::instance(), MusicPlayedListPopWidget::instance(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicSongItem::m_itemIndex, MusicFunctionToolBoxWidget::m_itemList, MusicSongItem::m_itemWidget, m_playRowIndex, MusicSongItem::m_songs, MUSIC_NORMAL_LIST, MusicApplication::playIndexBy(), MusicPlayedListPopWidget::remove(), MusicFunctionToolBoxWidget::removeItem(), MusicFunctionToolBoxWidget::setCurrentIndex(), MusicMessageBox::setText(), TTK_NORMAL_LEVEL, and updatePlayedList().
Referenced by setInputModule().
|
slot |
Delete all items in play list item.
Definition at line 428 of file musicsongscontainerwidget.cpp.
References MusicAbstractSongsListTableWidget::clearItems(), closeSearchWidgetInNeed(), MusicFunctionToolBoxWidget::foundMappedIndex(), MusicApplication::instance(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, m_playRowIndex, m_selectDeleteIndex, MUSIC_NONE_LIST, MusicApplication::playIndexBy(), TTK_NORMAL_LEVEL, and TTKObjectCast.
Referenced by setInputModule().
|
slot |
Delete all other item, left than three item.
Definition at line 404 of file musicsongscontainerwidget.cpp.
References MusicAbstractMoveDialog::exec(), MusicApplication::instance(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicFunctionToolBoxWidget::m_itemList, MusicSongItem::m_itemWidget, m_playRowIndex, MUSIC_NORMAL_LIST, MusicApplication::playIndexBy(), TTK::playlistRowValid(), MusicFunctionToolBoxWidget::removeItem(), MusicFunctionToolBoxWidget::setCurrentIndex(), MusicMessageBox::setText(), and TTK_NORMAL_LEVEL.
Referenced by contextMenuEvent().
|
finaloverrideprivatevirtual |
Definition at line 1026 of file musicsongscontainerwidget.cpp.
|
finaloverrideprivatevirtual |
Definition at line 1033 of file musicsongscontainerwidget.cpp.
References MusicFunctionToolBoxWidget::m_itemList, TTK::playlistRowValid(), and qAsConst.
|
finaloverrideprivatevirtual |
Definition at line 1056 of file musicsongscontainerwidget.cpp.
References MusicFunctionToolBoxWidget::foundMappedIndex(), importMusicSongsByPath(), MusicFunctionToolBoxWidget::m_itemList, TTK::playlistRowValid(), and qAsConst.
void MusicSongsContainerWidget::importMusicSongsByPath | ( | const QStringList & | files, |
int | playlistRow | ||
) |
Input imported music datas into container.
Definition at line 185 of file musicsongscontainerwidget.cpp.
References closeSearchWidgetInNeed(), TTK::generateSongList(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicSongItem::m_itemWidget, MusicSongItem::m_songs, MusicSongsToolBoxWidget::makeValidIndex(), MusicToastLabel::popup(), qAsConst, MusicFunctionToolBoxWidget::setCurrentIndex(), setItemTitle(), MusicProgressWidget::setTitle(), MusicProgressWidget::show(), and MusicAbstractSongsListTableWidget::updateSongsList().
Referenced by addSongToPlaylist(), dropEvent(), importMusicSongsByUrl(), MusicApplication::importSongsByFiles(), and MusicApplication::importSongsByOutside().
Input imported music urls into container.
Definition at line 129 of file musicsongscontainerwidget.cpp.
References closeSearchWidgetInNeed(), TTK::File::fileInfoListByPath(), importMusicSongsByPath(), TTK::String::isNetworkUrl(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicSongItem::m_itemWidget, MusicSongItem::m_songs, MusicSongsToolBoxWidget::makeValidIndex(), TTK::Algorithm::md5(), MUSIC_NETWORK_LIST, TTK::String::pefix(), setItemTitle(), TTK::String::splitToken(), MusicFormats::supportMusicFormats(), TTK_DEFAULT_STR, TTK_FILE_SUFFIX, TTK_SEPARATOR, and MusicAbstractSongsListTableWidget::updateSongsList().
Referenced by MusicApplication::importSongsByDir(), and MusicApplication::importSongsByUrl().
|
slot |
Import music songs by dir.
Definition at line 552 of file musicsongscontainerwidget.cpp.
References MusicFunctionToolBoxWidget::foundMappedIndex(), MusicApplication::importSongsByDir(), MusicApplication::instance(), MusicFunctionToolBoxWidget::m_currentIndex, and TTK_LOW_LEVEL.
Referenced by setInputModule().
|
slot |
Import music songs by files.
Definition at line 532 of file musicsongscontainerwidget.cpp.
References MusicFunctionToolBoxWidget::foundMappedIndex(), MusicApplication::importSongsByFiles(), MusicApplication::instance(), MusicFunctionToolBoxWidget::m_currentIndex, and TTK_LOW_LEVEL.
Referenced by setInputModule().
|
slot |
Check is current play stack widget.
Definition at line 838 of file musicsongscontainerwidget.cpp.
References MusicFunctionToolBoxWidget::currentIndex(), MusicFunctionToolBoxWidget::m_currentIndex, m_playRowIndex, m_selectDeleteIndex, and MUSIC_NONE_LIST.
Referenced by createWidgetItem().
|
slot |
Check current list is searched or not.
Definition at line 844 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::hasSearchResult().
Referenced by createWidgetItem().
|
inlineprivate |
Current index is searched or not.
Definition at line 254 of file musicsongscontainerwidget.h.
References MusicFunctionToolBoxWidget::m_currentIndex.
Referenced by removeSearchResult(), and searchResultChanged().
|
slot |
Swap the current play index when user drag and drop.
Definition at line 812 of file musicsongscontainerwidget.cpp.
References MusicPlayedListPopWidget::instance(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicFunctionToolBoxWidget::m_currentIndex, m_playRowIndex, QtContainerSwap, and MusicPlayedListPopWidget::selectCurrentIndex().
Referenced by createWidgetItem().
|
inline |
Query music datas from container.
Definition at line 58 of file musicsongscontainerwidget.h.
References MusicItemSearchInterface< T >::m_containerItems.
Referenced by addMusicItemList(), MusicApplication::containsLovestItem(), MusicApplication::currentFileName(), MusicApplication::currentFilePath(), MusicApplication::exportSongsItemList(), MusicApplication::playIndexBy(), MusicApplication::playIndexClicked(), updatePlayedList(), and MusicApplication::writeSystemConfigToFile().
Map music file path by song index.
Definition at line 277 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::m_containerItems.
Referenced by MusicApplication::playIndexBy(), MusicApplication::playSortBy(), and MusicApplication::readSystemConfigFromFile().
int MusicSongsContainerWidget::mapSongIndexByFilePath | ( | int | playlistRow, |
const QString & | path | ||
) | const |
Map music song index by file path.
Definition at line 259 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::m_containerItems.
Referenced by MusicApplication::addSongToLovestList(), MusicApplication::containsLovestItem(), MusicApplication::currentFileName(), MusicApplication::currentFilePath(), MusicApplication::currentPlayLocation(), MusicApplication::showCurrentSong(), and MusicApplication::writeSystemConfigToFile().
QStringList MusicSongsContainerWidget::musicSongsFileName | ( | int | index | ) | const |
Get music songs file name by index.
Definition at line 228 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::m_containerItems, and qAsConst.
Referenced by MusicApplication::currentPlaylist(), and searchResultChanged().
QStringList MusicSongsContainerWidget::musicSongsFilePath | ( | int | index | ) | const |
Get music songs file path by index.
Definition at line 244 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::m_containerItems, and qAsConst.
Referenced by MusicApplication::readSystemConfigFromFile(), and MusicApplication::setPlayIndex().
void MusicSongsContainerWidget::playLocation | ( | int | index | ) |
Show current play index.
Definition at line 328 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::hasSearchResult(), MusicFunctionToolBoxWidget::resizeScrollIndex(), and selectRow().
Referenced by MusicApplication::currentPlayLocation().
|
inline |
Get current play row index.
Definition at line 94 of file musicsongscontainerwidget.h.
Referenced by MusicApplication::containsDownloadItem(), and MusicApplication::containsLovestItem().
|
slot |
Query music datas from container.
Definition at line 909 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::m_containerItems.
|
slot |
Remove items from indexs and check remove file or not.
Definition at line 772 of file musicsongscontainerwidget.cpp.
References MusicApplication::addSongToLovestList(), MusicFunctionToolBoxWidget::currentIndex(), TTK::generateNetworkSongPath(), MusicItemSearchInterface< MusicSongItemList >::hasSearchResult(), MusicApplication::instance(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicFunctionToolBoxWidget::m_currentIndex, MusicSongItem::m_itemWidget, m_playRowIndex, m_selectDeleteIndex, MusicSongItem::m_songs, MUSIC_LOVEST_LIST, MUSIC_NETWORK_LIST, MUSIC_NONE_LIST, MusicSong::path(), MusicApplication::removeItemAt(), setItemTitle(), and TTKObjectCast.
Referenced by createWidgetItem().
void MusicSongsContainerWidget::removeSearchResult | ( | int & | row | ) |
Get search result index from list by given row and clear cache.
Definition at line 293 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::clearSearchResult(), closeSearchWidget(), MusicItemSearchInterface< MusicSongItemList >::hasSearchResult(), isSearchPlayIndex(), MusicItemSearchInterface< MusicSongItemList >::m_searchResultItems, and MusicItemSearchInterface< MusicSongItemList >::m_searchResultLevel.
Referenced by MusicApplication::playIndexBy().
|
finaloverrideprivatevirtual |
Override the widget event.
Definition at line 1020 of file musicsongscontainerwidget.cpp.
References resizeWindow().
|
private |
Resize window bound by resize called.
Definition at line 1201 of file musicsongscontainerwidget.cpp.
References m_listFunctionWidget, and m_songSearchWidget.
Referenced by resizeEvent(), showFloatWidget(), and showSearchWidget().
Search result from list.
Definition at line 582 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::clearSearchResult(), isSearchPlayIndex(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicFunctionToolBoxWidget::m_currentIndex, MusicSongItem::m_itemWidget, m_lastSearchIndex, MusicItemSearchInterface< MusicSongItemList >::m_searchResultItems, MusicItemSearchInterface< MusicSongItemList >::m_searchResultLevel, MusicSongItem::m_songs, m_songSearchWidget, musicSongsFileName(), MusicSongSearchDialog::text(), TTKObjectCast, and MusicAbstractSongsListTableWidget::updateSongsList().
void MusicSongsContainerWidget::selectRow | ( | int | index | ) |
Select the current play row.
Definition at line 337 of file musicsongscontainerwidget.cpp.
References closeSearchWidgetInNeed(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, m_playRowIndex, and MusicFunctionToolBoxWidget::setCurrentIndex().
Referenced by playLocation(), and MusicApplication::showCurrentSong().
void MusicSongsContainerWidget::setCurrentSongTreeIndex | ( | int | index | ) |
Set current song tree index.
Definition at line 313 of file musicsongscontainerwidget.cpp.
References MusicSongsListPlayTableWidget::adjustPlayWidgetRow(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, m_playRowIndex, and TTKObjectCast.
Referenced by MusicApplication::setPlayIndex(), and MusicApplication::showCurrentSong().
|
private |
Set input connection.
Definition at line 1187 of file musicsongscontainerwidget.cpp.
References addNewRowItem(), addToPlayedList(), addToPlayLater(), changRowItemName(), deleteRowItem(), deleteRowItemAll(), importSongsByDir(), importSongsByFiles(), songListSortBy(), and swapDragItemIndex().
Referenced by createWidgetItem(), and MusicSongsContainerWidget().
|
private |
Set item title.
Definition at line 1176 of file musicsongscontainerwidget.cpp.
References MusicFunctionToolBoxTopWidget::index(), MusicSongItem::m_itemIndex, MusicSongItem::m_itemName, MusicSongItem::m_itemWidget, m_listMaskWidget, MusicSongItem::m_songs, MusicFunctionToolBoxTopWidget::setTitle(), and MusicFunctionToolBoxWidget::setTitle().
Referenced by addSongBufferToPlaylist(), addSongToLovestList(), changRowItemName(), importMusicSongsByPath(), importMusicSongsByUrl(), removeItemAt(), and songToLovestListAt().
|
slot |
Set current music song play count by given song index.
Definition at line 849 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::m_containerItems, m_playRowIndex, MusicSong::playCount(), and MusicSong::setPlayCount().
Referenced by MusicApplication::showCurrentSong(), and updateCurrentIndex().
|
slot |
Input recent imported music datas into container.
Definition at line 864 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicSongItem::m_itemName, MusicSongItem::m_itemWidget, m_playRowIndex, MusicSongItem::m_songs, MUSIC_NETWORK_LIST, MUSIC_RECENT_LIST, RECENT_ITEM_MAX_COUNT, MusicSongsListPlayTableWidget::removeItems(), MusicFunctionToolBoxWidget::setTitle(), TTKObjectCast, and MusicSongsListPlayTableWidget::updateSongsList().
Referenced by MusicApplication::showCurrentSong().
|
slot |
Show the float function widget.
Definition at line 924 of file musicsongscontainerwidget.cpp.
References MusicSongsListFunctionWidget::active(), deleteFloatWidget(), m_listFunctionWidget, and resizeWindow().
Referenced by createWidgetItem().
|
slot |
Open lrc batch download.
Definition at line 577 of file musicsongscontainerwidget.cpp.
References TTKGenerateSingleWidget.
Referenced by contextMenuEvent().
|
privateslot |
Show searched text widget.
Definition at line 985 of file musicsongscontainerwidget.cpp.
References m_songSearchWidget, resizeWindow(), and MusicSongSearchDialog::setVisible().
|
slot |
Open music songs check test tools.
Definition at line 572 of file musicsongscontainerwidget.cpp.
References TTKGenerateSingleWidget.
Referenced by contextMenuEvent().
|
privateslot |
Current vertical slider value chanaged.
Definition at line 996 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicFunctionToolBoxWidget::m_currentIndex, MusicSongItem::m_itemIndex, MusicSongItem::m_itemName, m_listMaskWidget, MusicSongItem::m_songs, MusicSongItem::m_sort, MusicFunctionToolBoxTopWidget::setExpand(), MusicFunctionToolBoxTopWidget::setIndex(), MusicSongsToolBoxTopWidget::setSongSort(), and MusicFunctionToolBoxTopWidget::setTitle().
Referenced by MusicSongsContainerWidget().
|
slot |
Music list songs sort by type.
Definition at line 940 of file musicsongscontainerwidget.cpp.
References MusicSong::ByFileName, closeSearchWidgetInNeed(), MusicFunctionToolBoxWidget::foundMappedIndex(), MusicApplication::instance(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicFunctionToolBoxWidget::m_currentIndex, m_playRowIndex, MusicApplication::playSortBy(), MusicSongsListPlayTableWidget::removeItems(), MusicAbstractSongsListTableWidget::setSongsList(), TTKObjectCast, and TTKStaticCast.
Referenced by createWidgetItem(), and setInputModule().
|
slot |
Add or remove music song to lovest list by row.
Add to lovest list
Remove to lovest list
Definition at line 655 of file musicsongscontainerwidget.cpp.
References MusicApplication::instance(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicSongItem::m_itemWidget, m_playRowIndex, MusicSongItem::m_songs, MUSIC_LOVEST_LIST, MusicSong::path(), MusicSongsListPlayTableWidget::removeItems(), MusicApplication::removeLoveItemAt(), setItemTitle(), TTKObjectCast, and MusicSongsListPlayTableWidget::updateSongsList().
Referenced by MusicApplication::addSongToLovestList().
Swap the item index by drag adn drop.
Definition at line 468 of file musicsongscontainerwidget.cpp.
References MusicFunctionToolBoxWidget::foundMappedIndex(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, MusicFunctionToolBoxWidget::m_currentIndex, m_playRowIndex, MusicFunctionToolBoxWidget::swapItem(), and updatePlayedList().
Referenced by setInputModule().
|
slot |
Update current artist when it download finished.
Definition at line 914 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::m_containerItems, m_playRowIndex, and TTKObjectCast.
Referenced by MusicApplication::updateCurrentArtist().
|
slot |
Update current play index from config file.
Definition at line 639 of file musicsongscontainerwidget.cpp.
References G_SETTING_PTR, MusicApplication::instance(), MusicSettingManager::LastPlayIndex, m_playRowIndex, MusicFunctionToolBoxWidget::setCurrentIndex(), setMusicPlayCount(), and MusicApplication::showCurrentSong().
void MusicSongsContainerWidget::updateDurationLabel | ( | const QString & | current, |
const QString & | total | ||
) | const |
Update item duration label.
Definition at line 349 of file musicsongscontainerwidget.cpp.
References MusicItemSearchInterface< MusicSongItemList >::m_containerItems, m_playRowIndex, and TTKObjectCast.
Referenced by MusicApplication::positionChanged().
Update current played list.
Definition at line 1214 of file musicsongscontainerwidget.cpp.
References MusicFunctionToolBoxWidget::foundMappedIndex(), MusicPlayedListPopWidget::instance(), items(), MusicItemSearchInterface< MusicSongItemList >::m_containerItems, qAsConst, and MusicPlayedListPopWidget::updatePlayedList().
Referenced by deleteRowItem(), and swapDragItemIndex().
|
private |
Definition at line 293 of file musicsongscontainerwidget.h.
Referenced by searchResultChanged().
|
private |
Definition at line 297 of file musicsongscontainerwidget.h.
Referenced by deleteFloatWidget(), resizeWindow(), showFloatWidget(), and ~MusicSongsContainerWidget().
|
private |
Definition at line 296 of file musicsongscontainerwidget.h.
Referenced by MusicSongsContainerWidget(), setItemTitle(), sliderValueChanaged(), and ~MusicSongsContainerWidget().
|
private |
Definition at line 292 of file musicsongscontainerwidget.h.
Referenced by addSongToLovestList(), deleteRowItem(), deleteRowItemAll(), deleteRowItems(), isCurrentPlaylistRow(), itemIndexSwaped(), removeItemAt(), selectRow(), setCurrentSongTreeIndex(), setMusicPlayCount(), setRecentMusicSongs(), songListSortBy(), songToLovestListAt(), swapDragItemIndex(), updateCurrentArtist(), updateCurrentIndex(), and updateDurationLabel().
|
private |
Definition at line 294 of file musicsongscontainerwidget.h.
Referenced by deleteRowItemAll(), isCurrentPlaylistRow(), and removeItemAt().
|
private |
Definition at line 298 of file musicsongscontainerwidget.h.
Referenced by closeSearchWidget(), resizeWindow(), searchResultChanged(), showSearchWidget(), and ~MusicSongsContainerWidget().