diff options
author | Anton Khirnov <wyskas@gmail.com> | 2009-09-19 10:49:10 +0200 |
---|---|---|
committer | Anton Khirnov <wyskas@gmail.com> | 2009-09-19 10:49:10 +0200 |
commit | a5019465a52dbbe17c625c1c1045427c5059fe9e (patch) | |
tree | 661759b271577b66218ec96e263b63a95cc9ed57 /nephilim/plugins/Library.py | |
parent | 6f1cf7b125325ec2d95986a60ee34ca127129fc8 (diff) |
Playlist: support for moving songs with drag&drop
Diffstat (limited to 'nephilim/plugins/Library.py')
-rw-r--r-- | nephilim/plugins/Library.py | 20 |
1 files changed, 1 insertions, 19 deletions
diff --git a/nephilim/plugins/Library.py b/nephilim/plugins/Library.py index 348069c..c746af6 100644 --- a/nephilim/plugins/Library.py +++ b/nephilim/plugins/Library.py @@ -19,7 +19,7 @@ from PyQt4 import QtGui, QtCore from PyQt4.QtCore import QVariant from ..plugin import Plugin -from ..common import MIMETYPES +from ..common import MIMETYPES, SongsMimeData class Library(Plugin): # public, const @@ -260,21 +260,3 @@ class LibraryWidget(QtGui.QWidget): paths.append(song) self.plugin.mpclient.add(paths) -class SongsMimeData(QtCore.QMimeData): - # private - __songs = None - - def set_songs(self, songs): - self.__songs = songs - - def songs(self): - return self.__songs - - def formats(self): - types = QtCore.QMimeData.formats(self) - return types if not self.__songs else types + [MIMETYPES['songs']] - - def hasFormat(self, format): - if format == MIMETYPES['songs'] and self.__songs: - return True - return QtCore.QMimeData.hasFormat(self, format) |