mirror of
https://github.com/leozide/leocad
synced 2024-12-27 21:58:37 +01:00
46 lines
932 B
C++
46 lines
932 B
C++
#ifndef LC_QEDITGROUPSDIALOG_H
|
|
#define LC_QEDITGROUPSDIALOG_H
|
|
|
|
#include <QDialog>
|
|
struct lcEditGroupsDialogOptions;
|
|
|
|
namespace Ui {
|
|
class lcQEditGroupsDialog;
|
|
}
|
|
|
|
class lcQEditGroupsDialog : public QDialog
|
|
{
|
|
Q_OBJECT
|
|
|
|
public:
|
|
explicit lcQEditGroupsDialog(QWidget *parent, void *data);
|
|
~lcQEditGroupsDialog();
|
|
|
|
lcEditGroupsDialogOptions *options;
|
|
|
|
enum
|
|
{
|
|
PieceRole = Qt::UserRole,
|
|
GroupRole
|
|
};
|
|
|
|
public slots:
|
|
void accept();
|
|
void on_newGroup_clicked();
|
|
void onItemClicked(QTreeWidgetItem *item, int col);
|
|
void onItemDoubleClicked(QTreeWidgetItem *item, int col);
|
|
|
|
private:
|
|
Ui::lcQEditGroupsDialog *ui;
|
|
|
|
void updateParents(QTreeWidgetItem *parentItem, lcGroup *parentGroup);
|
|
void addChildren(QTreeWidgetItem *parentItem, lcGroup *parentGroup);
|
|
|
|
void timerEvent(QTimerEvent *event);
|
|
|
|
QTreeWidgetItem* m_lastItemClicked;
|
|
bool m_editableDoubleClicked;
|
|
QBasicTimer m_clickTimer;
|
|
};
|
|
|
|
#endif // LC_QEDITGROUPSDIALOG_H
|