00001 #ifndef FOLDERTABLEDELEGATE_H 00002 #define FOLDERTABLEDELEGATE_H 00003 00004 #include <QtGui/QItemDelegate> 00005 00006 00007 class FolderTableDelegate: public QItemDelegate 00008 { 00009 Q_OBJECT 00010 00011 public: 00012 FolderTableDelegate( QObject* parent = 0 ); 00013 ~FolderTableDelegate(); 00014 QWidget* createEditor( QWidget* parent, const QStyleOptionViewItem& option, const QModelIndex& index ) const; 00015 void setEditorData( QWidget* editor, const QModelIndex& index ) const; 00016 void setModelData( QWidget* editor, QAbstractItemModel* model, const QModelIndex& index ) const; 00017 void updateEditorGeometry( QWidget* editor, const QStyleOptionViewItem& option, const QModelIndex& index ) const; 00018 00019 private slots: 00020 void commitAndCloseEditor(); 00021 }; 00022 00023 #endif