Subversion Repositories OpenInventory

Rev

Rev 66 | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed

#ifndef DELEGATEFORCLASSESTABLE_H
#define DELEGATEFORCLASSESTABLE_H


#include <QItemDelegate>
#include <QModelIndex>
#include <QObject>
#include <QSize>
#include <QSpinBox>

class DelegateForClassesTable : public QItemDelegate
{
Q_OBJECT
public:
    explicit DelegateForClassesTable(QObject *parent = 0);

    QWidget *createEditor(QWidget *parent, const QStyleOptionViewItem &option,
                          const QModelIndex &index) const;

    void setEditorData(QWidget *editor, const QModelIndex &index) const;
    void setModelData(QWidget *editor, QAbstractItemModel *model,
                      const QModelIndex &index) const;

    void updateEditorGeometry(QWidget *editor,
        const QStyleOptionViewItem &option, const QModelIndex &index) const;

    void setItems(QStringList new_items); // äîáàâëÿåì íîâûå ïóíêòû â äåëåãàò

private:
    QStringList items;

signals:

public slots:

};





#endif // DELEGATEFORCLASSESTABLE_H