]> git.sesse.net Git - vlc/blobdiff - modules/gui/qt4/components/playlist/playlist_model.hpp
Qt4: don't cache current
[vlc] / modules / gui / qt4 / components / playlist / playlist_model.hpp
index 99f82996bae0e7bf3a93269ff5d1f4e002be8d5c..f6343dfebae8adca8b79c2cc1c161926f3a287c3 100644 (file)
@@ -59,7 +59,8 @@ friend class PLSelector;
 public:
     enum {
       IsCurrentRole = Qt::UserRole,
-      IsLeafNodeRole
+      IsLeafNodeRole,
+      IsCurrentsParentNodeRole
     };
 
     PLModel( playlist_t *, intf_thread_t *,
@@ -92,6 +93,7 @@ public:
     QModelIndex index( PLItem *, int c ) const;
     QModelIndex index( int i_id, int c );
     QModelIndex currentIndex();
+    bool isParent( const QModelIndex &index, const QModelIndex &current) const;
     bool isCurrent( const QModelIndex &index ) const;
     int itemId( const QModelIndex &index ) const;
     static int columnFromMeta( int meta_column );
@@ -142,8 +144,7 @@ private:
     void updateChildren( playlist_item_t *, PLItem * );
 
     /* Deep actions (affect core playlist) */
-    static void recursiveAppendCopy( playlist_t *, playlist_item_t *, playlist_item_t *, bool );
-    void dropAppendCopy( const PlMimeData * data, PLItem *target );
+    void dropAppendCopy( const PlMimeData * data, PLItem *target, int pos );
     void dropMove( const PlMimeData * data, PLItem *target, int new_pos );
 
     /* Popup */
@@ -180,7 +181,7 @@ private slots:
 
 class PlMimeData : public QMimeData
 {
-    Q_OBJECT;
+    Q_OBJECT
 
 public:
     PlMimeData();