X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fsubprojectitem.h;h=5332e1db9f56ff8d8095c702a45a6ce652456038;hb=56aee6aedeeed3efd10ada8fe3c229eddc01ef05;hp=fc8e4a4fcc5a4a9496e32e288e342c81381c2bb2;hpb=880efc8572a7df65453dfb5736de6455fe129a86;p=kdenlive diff --git a/src/subprojectitem.h b/src/subprojectitem.h index fc8e4a4f..5332e1db 100644 --- a/src/subprojectitem.h +++ b/src/subprojectitem.h @@ -38,16 +38,29 @@ class DocClipBase; class SubProjectItem : public QTreeWidgetItem { public: - SubProjectItem(QTreeWidgetItem * parent, int in, int out); + SubProjectItem(double display_ratio, QTreeWidgetItem * parent, int in, int out, const QString& description = QString()); virtual ~SubProjectItem(); QDomElement toXml() const; int numReferences() const; DocClipBase *referencedClip(); QPoint zone() const; + void setZone(const QPoint &p); + QString description() const; + void setDescription(const QString& desc); + static int itemDefaultHeight(); + + /** Make sure folders appear on top of the tree widget */ + virtual bool operator<(const QTreeWidgetItem &other)const { + int column = treeWidget()->sortColumn(); + if (other.type() != ProjectFoldeType) + return text(column).toLower() < other.text(column).toLower(); + else return false; + } private: int m_in; int m_out; + QString m_description; }; #endif