aboutsummaryrefslogtreecommitdiff
path: root/src/qmmpui/playlistmodel.h
diff options
context:
space:
mode:
authortrialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38>2010-11-01 17:54:27 +0000
committertrialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38>2010-11-01 17:54:27 +0000
commit24af8da3f8942c200ba0058341a66a888224aa3c (patch)
treec01647eef52405ff06ed13e6d151b75cddde3834 /src/qmmpui/playlistmodel.h
parent15d744d752d16aa5621c98cd2de2d6ce3f6e6f46 (diff)
downloadqmmp-24af8da3f8942c200ba0058341a66a888224aa3c.tar.gz
qmmp-24af8da3f8942c200ba0058341a66a888224aa3c.tar.bz2
qmmp-24af8da3f8942c200ba0058341a66a888224aa3c.zip
changed playlist api, prepare for shortcut editor implementation, fixed direcory scan order (Closes issue 207)
git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@1970 90c681e8-e032-0410-971d-27865f9a5e38
Diffstat (limited to 'src/qmmpui/playlistmodel.h')
-rw-r--r--src/qmmpui/playlistmodel.h57
1 files changed, 18 insertions, 39 deletions
diff --git a/src/qmmpui/playlistmodel.h b/src/qmmpui/playlistmodel.h
index ac5668ffa..b44270758 100644
--- a/src/qmmpui/playlistmodel.h
+++ b/src/qmmpui/playlistmodel.h
@@ -298,6 +298,10 @@ signals:
* @param name New playlist name.
*/
void nameChanged(const QString& name);
+ /*!
+ * Emitted when playlist loader thread has finished.
+ */
+ void loaderFinished();
public slots:
/*!
@@ -306,10 +310,20 @@ public slots:
void add(PlayListItem *item);
/*!
* Adds a list of items to the playlist.
- * @param items List of items
+ * @param items List of items.
*/
void add(QList <PlayListItem *> items);
/*!
+ * Adds a list of files and directories to the playlist
+ * @param path Full path of file or directory.
+ */
+ void add(const QString &path);
+ /*!
+ * Adds a list of files and directories to the playlist
+ * @param paths Full paths of files and directories.
+ */
+ void add(const QStringList &paths);
+ /*!
* Removes all items.
*/
void clear();
@@ -343,35 +357,14 @@ public slots:
void selectAll();
/*!
* Shows details for the first selected item.
+ * @param parent parent Widget.
*/
- void showDetails();
+ void showDetails(QWidget *parent = 0);
/*!
* Emits update signals manually.
*/
void doCurrentVisibleRequest();
/*!
- * Adds file \b path to the playlist. File should be supported.
- */
- void addFile(const QString &path);
- /*!
- * Adds the list \b l of files to the model.
- */
- void addFiles(const QStringList& l);
- /*!
- * Adds \b dir to the model.
- */
- void addDirectory(const QString& dir);
- /*!
- * Removes previous items and loads list of files (regular files or directories),
- * returns \b true if at least one file has been successfully loaded,
- * otherwise returns \b false
- */
- bool setFileList(const QStringList &l);
- /*!
- * Loads list of files (regular files or directories)
- */
- void addFileList(const QStringList &l);
- /*!
* Randomly changes items order.
*/
void randomizeList();
@@ -434,14 +427,6 @@ private:
*/
int bottommostInSelection(int);
/*!
- * Creates and initializes file loader object.
- */
- FileLoader* createFileLoader();
- /*!
- * Is someone of file loaders is running?
- */
- bool isFileLoaderRunning()const;
- /*!
* Removes items from model. If \b inverted is \b false -
* selected items will be removed, else - unselected.
*/
@@ -473,13 +458,7 @@ private:
*/
PlayState* m_play_state;
int m_total_length;
- typedef QPointer<FileLoader> GuardedFileLoader;
- /*!
- * Vector of currently running file loaders.
- * All loaders are automatically sheduled for deletion
- * when finished.
- */
- QVector<GuardedFileLoader> m_running_loaders;
+ FileLoader *m_loader;
bool m_shuffle;
QString m_name;
};