Miam-Player  0.8.0
A nice music player
FileSystemTreeView Class Reference

The FileSystemTreeView class is displaying a standard file-system in a tree. More...

#include <filesystemtreeview.h>

Inheritance diagram for FileSystemTreeView:
TreeView SelectedTracksModel

Public Slots

void reloadWithNewPath (const QDir &path)
- Public Slots inherited from TreeView
void appendToPlaylist ()
void insertToPlaylist (int rowIndex)
void openTagEditor ()


void aboutToAddMusicLocations (const QList< QDir > &)
void folderChanged (const QString &)
- Signals inherited from TreeView
void aboutToInsertToPlaylist (int rowIndex, const QStringList &tracks)
void sendToTagEditor (const QModelIndexList indexes, const QStringList &tracks)

Public Member Functions

 FileSystemTreeView (QWidget *parent=nullptr)
virtual void findAll (const QModelIndex &index, QStringList &tracks) const override
virtual void updateSelectedTracks () override
- Public Member Functions inherited from TreeView
 TreeView (QWidget *parent=nullptr)
virtual QStringList selectedTracks () override
- Public Member Functions inherited from SelectedTracksModel
virtual ~SelectedTracksModel ()

Protected Member Functions

virtual void contextMenuEvent (QContextMenuEvent *event) override
virtual int countAll (const QModelIndexList &indexes) const override
virtual bool eventFilter (QObject *obj, QEvent *event) override
virtual void keyPressEvent (QKeyEvent *event) override
- Protected Member Functions inherited from TreeView
virtual void startDrag (Qt::DropActions supportedActions) override

Additional Inherited Members

- Protected Attributes inherited from TreeView
QModelIndexList _cacheSelectedIndexes

Detailed Description

The FileSystemTreeView class is displaying a standard file-system in a tree.

This view allows one to browse folders and files from a standard file-system. Non playable files are disabled, excepted for covers. One can send files, folders, and both to playlist or tag editor.

Matthieu Bachelier

Constructor & Destructor Documentation

FileSystemTreeView::FileSystemTreeView ( QWidget *  parent = nullptr)

Member Function Documentation

void FileSystemTreeView::aboutToAddMusicLocations ( const QList< QDir > &  )

Append the selected folder to the existing music locations.

void FileSystemTreeView::contextMenuEvent ( QContextMenuEvent *  event)

Reimplemented to display up to 3 actions.

int FileSystemTreeView::countAll ( const QModelIndexList &  indexes) const

Reimplemented with a QDirIterator to quick count tracks.

Implements TreeView.

bool FileSystemTreeView::eventFilter ( QObject *  obj,
QEvent *  event 

Redefined to override shortcuts that are mapped on simple keys.

void FileSystemTreeView::findAll ( const QModelIndex &  index,
QStringList &  tracks 
) const

Reimplemented with a QDirIterator to gather informations about tracks.

Implements TreeView.

void FileSystemTreeView::folderChanged ( const QString &  )
void FileSystemTreeView::keyPressEvent ( QKeyEvent *  event)
void FileSystemTreeView::reloadWithNewPath ( const QDir &  path)

Reload tree when the path has changed in the address bar.

void FileSystemTreeView::updateSelectedTracks ( )

Implements SelectedTracksModel.

The documentation for this class was generated from the following files: